Garrett19212 Posted July 8, 2005 Share Posted July 8, 2005 Iv tried Run, to open a txt file but it didn't work, how would i open a txt file, in the same folder as the script? Link to comment Share on other sites More sharing options...
Garrett19212 Posted July 8, 2005 Author Share Posted July 8, 2005 Thx, the first one didn't work, but the second one did. Link to comment Share on other sites More sharing options...
ezzetabi Posted July 8, 2005 Share Posted July 8, 2005 Func to start any file type with its associated program: Func _ShellExecuteDllCall($sCmd, $sVerb = 'Open', $sArg = '', $sFolder = '') Local $aRet $aRet = DllCall("shell32.dll", "long", "ShellExecute", "hwnd", 0, "string", $sVerb, _ "string", $sCmd, "string", $sArg, "string", $sFolder, "long", @SW_SHOWNORMAL) If $aRet[0] > 32 Then Return 1 Else Return 0 EndIf ;return will be 0 if something goes wrong. EndFunc ;==>_ShellExecuteDllCall Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now