Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Accessing files in current macro's directory
#2
Open or create function init2. Put this code. Run init2 or restart QM.

Code:
Copy      Help
rget _s "file" "Software\Gindi\QM2\settings"
_s.getpath(_s "")
_s-"qml="
_putenv _s

This code gets path of current QM macro list file and stores into environment variable qml. An environment variable in file functions (including scan) is expanded if it is enclosed in % and is at the beginning. For example, "%qml%\a.bmp" will be expanded to "C:\Macros\SomePrg\a.bmp"


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)