07-24-2012, 11:28 PM
Hello,
My apologies for the difficult description for a "simple problem".
I am currently finishing up my first macro, but I have the following "problem".
The compiled macro (.exe) uses an argument which I provide in a windows shortcut.
I have the compiled executable "winlauncher.exe"
And it gets a parameter in the form of a path to a textfile and a extra string which are provided in the windows shortcut of the .exe file.
The shortcut would look something like this:
executable => c:\winlauncher.exe
path to a text file => winlist=c:\winlist.txt
extra string => config=config2
I currently make a test variable "test_command" and fill it with the arguments:
path to a text file => winlist=c:\winlist.txt
extra string => config=config2
So it looks something like this
Then I create a piece of code that checks if the current filename is "qm"
Macro temp
Based on the code above I decide to use: "_command" or my test command variable "test_command"
Is there a better way to approach this?
Or is the method I am using fine?
Edit:
I now have another "major" problem, the function "RunTextAsFunction" can't be used in a macro that you want to compile to exe
its a simple key function
The macro works, but compiling to .exe is not possible
My apologies for the difficult description for a "simple problem".
I am currently finishing up my first macro, but I have the following "problem".
The compiled macro (.exe) uses an argument which I provide in a windows shortcut.
I have the compiled executable "winlauncher.exe"
And it gets a parameter in the form of a path to a textfile and a extra string which are provided in the windows shortcut of the .exe file.
The shortcut would look something like this:
executable => c:\winlauncher.exe
path to a text file => winlist=c:\winlist.txt
extra string => config=config2
I currently make a test variable "test_command" and fill it with the arguments:
path to a text file => winlist=c:\winlist.txt
extra string => config=config2
So it looks something like this
Then I create a piece of code that checks if the current filename is "qm"
Macro temp
str is_qm.getfilename(ExeFullPath)
if(is_qm="qm")
,;...actions using the "test_command" variable
else
,;...actions using the predifined "_command" variable
Based on the code above I decide to use: "_command" or my test command variable "test_command"
Is there a better way to approach this?
Or is the method I am using fine?
Edit:
I now have another "major" problem, the function "RunTextAsFunction" can't be used in a macro that you want to compile to exe
its a simple key function
The macro works, but compiling to .exe is not possible