Select file and open it in Notepad

Share your macros, knowledge, solutions, services, ...
Post Reply
Petr
Posts: 106
Joined: Tue Oct 18, 2016 1:12 pm

Select file and open it in Notepad

Post by Petr » Wed Nov 23, 2016 4:36 pm

This macro allows user to select a file that will be then open in Notepad.

Code: Select all

<#> Start of the macro
<cmds> 
<#> Get file to open

<var_oper>(vFile,"",SELECT_FILE,"","", "0")
<#> Esc or Cancel pressed - then exit macro

<if_str>("_vCanceled==1")
   <exitmacro>
<endif>

<#> Run Notepad and open file vFile
<execappex>("notepad.exe","vFile","",0,0)

<#> End of the macro 

Post Reply