|
下記の標準モジュールの処理を行う最プログレスバーコントロールを
ユーザーフォームで表示(動作)させたいのですが標準モジュール
及びユーザーフォームにはどのように記述すればよいのでしょうか、
どなたか教えて頂けないでしょうか。
Sub システム終了()
Application.Visible = False
Dim ShVisibility As Integer
counter = counter - 1
If counter <= -1 Then
ShVisibility = True
counter = 0
Else
ShVisibility = xlVeryHidden
End If
Worksheets("Sheet2").Visible = ShVisibility
Worksheets("マスター1").Visible = ShVisibility
Worksheets("触らないで!").Visible = ShVisibility
Worksheets("担当部署(A)").Visible = ShVisibility
Worksheets("担当部署(B)").Visible = ShVisibility
Worksheets("担当部署(C)").Visible = ShVisibility
Worksheets("担当部署(D)").Visible = ShVisibility
Worksheets("担当部署(E)").Visible = ShVisibility
Worksheets("グラフ").Visible = ShVisibility
Worksheets("Sheet3").Visible = ShVisibility
Worksheets("Sheet4").Visible = ShVisibility
counter = counter + 1
If counter >= 2 Then
ShVisibility = True
counter = 0
Else
ShVisibility = xlVeryHidden
End If
Worksheets("マスター1").Visible = ShVisibility
Worksheets("触らないで!").Visible = ShVisibility
Worksheets("担当部署(A)").Visible = ShVisibility
Worksheets("担当部署(B)").Visible = ShVisibility
Worksheets("担当部署(C)").Visible = ShVisibility
Worksheets("担当部署(D)").Visible = ShVisibility
Worksheets("担当部署(E)").Visible = ShVisibility
Worksheets("グラフ").Visible = ShVisibility
Worksheets("Sheet3").Visible = ShVisibility
Worksheets("Sheet4").Visible = ShVisibility
ThisWorkbook.Save
Application.EnableEvents = False
Application.Quit
End Sub
|
|