Home

Created By Wesley Griffin

 
 
 Show the Windows Run Dialog.
 
  Home > Source CodeSystem/API > Show Run Dialog.
 
  Place the following code into the code window of a form:
 
 
Private Declare Function SHRunDialog Lib "shell32" Alias "#61" (ByVal hOwner As Long, ByVal Unknown1 As Long, ByVal Unknown2 As Long, ByVal szTitle As String, ByVal szPrompt As String, ByVal uFlags As Long) As Long
 
  To show the Windows Run Down Dialog box just call the following code in a sub or function, you can change the dialog box's title and the prompt text on the dialog box.
 
 
Dim strTitle as String, strPrompt as String
strTitle = "Open File..."     'Change to whatever
strPrompt = "Choose File..."     'Change to Whatever
SHRunDialog Me.hWnd, 0, 0, strTitle, strPrompt, 0
 
 

 Top.

 
  Warning:
All material from this site must be used at own risk.  VB First Aid will take no responsibility for any loss of data or any other errors.  The material on this site was written for Visual Basic Version 6, therefore compatibility with other versions may cause errors.