Jump to content

Run a txt file?

Recommended Posts

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
      Return 0
  ;return will be 0 if something goes wrong.
EndFunc  ;==>_ShellExecuteDllCall
Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...