我想了好长时间了,没弄出来,发给我吧,谢谢.
星光依旧灿烂,激情仍然燃烧。因为有梦想所以我存在,你在你的领域里不惜青春,我在我的道路上不知疲倦。
控件自己添加吧。
form1的代码
Private Declare Function SetWindowPos Lib "user32" (ByVal hwnd As Long, ByVal hWndInsertAfter As Long, ByVal x As Long, ByVal y As Long, ByVal cx As Long, ByVal cy As Long, ByVal wFlags As Long) As Long
Const SWP_SHOWWINDOW = &H3
Private Sub Command1_Click()
Form2.Timer1.Enabled = True
Load Form2
Form2.Show 1
retvalue = SetWindowPos(Form2.hwnd, -1, 0, 0, 0, 0, SWP_SHOWWINDOW) '设置窗口在最前端显示
End Sub
Private Sub Form_Load()
Form1.Show
Form2.Show 1
retvalue = SetWindowPos(Form2.hwnd, -1, 0, 0, 0, 0, SWP_SHOWWINDOW) '设置窗口在最前端显示
End Sub
form2的代码
Private Sub Form_Load()
ProgressBar1.Value = 0
ProgressBar1.Min = 0
ProgressBar1.Max = 10
Timer1.Interval = 500
Timer1.Enabled = True
End Sub
Private Sub Timer1_Timer()
If ProgressBar1.Value < 10 Then
ProgressBar1.Value = ProgressBar1.Value + 1
Else
Unload Form2
Timer1.Enabled = False
End If
End Sub
我的问题无人答阿