Jump to content

Notepad++


Recommended Posts

Hey i cant seem to get this to work? please tell me how

 

here is the code

Run ( "C:\Program Files (x86)\Notepad++\notepad++.exe")
                
               ;It gets here then stops responding
                WinWaitActive("new 0 - Notepad++")

                Send ("{Ctrl}") ("O")

                Send("C:\Desktop\Article\Index")

                Send("!i")

            Case $iMsg = $idUndo_Btn
                ;MsgBox(64, "New GU", "You clicked on the Cancel button!")

        EndSelect

    WEnd
EndFunc

 

Link to comment
Share on other sites

  • Moderators

Hi, samtan117, welcome to the forum. You could do it like this instead:

Run("notepad.exe")
WinWaitActive("[CLASS:Notepad]", "")

 

Or simply use ShellExecute:

ShellExecute(<path to file>)

 

Edit: I swear this was for notepad when I looked at it last night :D

Edited by JLogan3o13
I'm apparently blind

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

If I understand, you want to open a file with Notepad++.

You can just give the full path name as parameter in the command line :

Run(@ProgramFilesDir & '\Notepad++\notepad++.exe "C:\Desktop\Article\Index"')

 

Edited by jguinch
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
 Share

  • Recently Browsing   0 members

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