home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Source Code / Visual Basic Source Code.iso / vbsource / docume1a / frmrun.frm < prev    next >
Encoding:
Text File  |  1999-09-10  |  733 b   |  35 lines

  1. Attribute VB_Name = "Module1"
  2.  Private Sub Command1_Click()
  3.  On Error GoTo ErrorHandler
  4.      Dim S
  5.      Dim T
  6.      T = Combo1.Text
  7.      S = Shell(T, 1)
  8.  Exit Sub
  9. ErrorHandler:
  10.      MsgBox "Please type in a correct executable file.", vbOKOnly
  11.      Combo1.SetFocus
  12.  End Sub
  13.  
  14.  Private Sub Command2_Click()
  15. ' Unload Me
  16.  MDIForm1.SetFocus
  17.  End Sub
  18.  
  19.  Private Sub Command3_Click()
  20.  MsgBox "No Help Topic is associated with this dialog", vbOKOnly
  21.  End Sub
  22.  
  23.  Private Sub Form_Load()
  24. ' Width = 0.4 * Screen.Width
  25. ' Height = 0.23 * Screen.Height
  26. ' Left = (Screen.Width - Width) / 2
  27. ' Top = (Screen.Height - Height) / 2
  28. ' Combo1.AddItem "Explorer"
  29. ' Combo1.AddItem "Notepad"
  30. ' Combo1.AddItem "Sol"
  31.  End Sub
  32.  
  33.  
  34.  
  35.