VB general open

MuK107

Senior member
Dec 30, 2001
270
0
0
how do i open a file that i dont know where the person is going to install the aplication?
 

BuckleDownBen

Banned
Jun 11, 2001
519
0
0
What was the error? You would need to append a "/" to the name it returns. try this:

Press Ctrl G, then type "?app.path"
 

MuK107

Senior member
Dec 30, 2001
270
0
0
i figured it out i just put in

Private Declare Function ShellExecute Lib "shell32.dll" Alias "ShellExecuteA" (ByVal hwnd As Long, ByVal lpOperation As String, ByVal lpFile As String, ByVal lpParameters As String, ByVal lpDirectory As String, ByVal nShowCmd As Long) As Long

Private Const SW_SHOWNORMAL = 1

ShellExecute Me.hwnd, vbNullString, "helpfile.CHM", vbNullString, App.Path, SW_SHOWNORMAL

and now it works