Hi!
I have some text variables: variable1, variable2, variable3, etc.
For each one I must make some tasks in Word (search and replace). I maked the script for this tasks, but I need:
execute some times the script for variable 1
then
execute some times for variable2
then
execute some times for variable3
etc.
How can I make it?
Thanks!
zopita - Spain
Text variables
Moderators: Dorian (MJT support), JRL
- Bob Hansen
- Automation Wizard
- Posts: 2475
- Joined: Tue Sep 24, 2002 3:47 am
- Location: Salem, New Hampshire, US
- Contact:
Not sure what you are doing, but maybe this will help.
Code: Select all
Let>Variable1=abc
Let>Variable2=def
Let>Variable3=ghi
Let>Count=0
Label>SomeProcess
Let>Count=Count+1
Let>SearchValue=Variable%Count%
MessageModal>Search value is %SearchValue%
// Copy Variable into clipboard and paste into Search field in Word
PutClipBoard>%SearchValue%
// Move to Search field and past from clipboard
Press>CTRL
Send>v
Release>CTRL
Wait>10
If>%Count%=3,End,SomeProcess
Label>End
Hope this was helpful..................good luck,
Bob
A humble man and PROUD of it!
Bob
A humble man and PROUD of it!
Re: Text variables
Hi zopita,
Use would then be as follows:
1) hit Hot Key 1 to execute for variable 1
2) hit Hot Key 2 to execute for variable 2
3) hit Hot Key 3 to execute for variable 3
The simple way would be to make three separate scripts and assign each one a separate Hot Key, lets call them Hot Keys 1, 2 and 3.zopita wrote:execute some times the script for variable 1
then
execute some times for variable2
then
execute some times for variable3
etc.
How can I make it?
Use would then be as follows:
1) hit Hot Key 1 to execute for variable 1
2) hit Hot Key 2 to execute for variable 2
3) hit Hot Key 3 to execute for variable 3
jpuziano
Note: If anyone else on the planet would find the following useful...
[Open] PlayWav command that plays from embedded script data
...then please add your thoughts/support at the above post -
Note: If anyone else on the planet would find the following useful...
[Open] PlayWav command that plays from embedded script data
...then please add your thoughts/support at the above post -
- Bob Hansen
- Automation Wizard
- Posts: 2475
- Joined: Tue Sep 24, 2002 3:47 am
- Location: Salem, New Hampshire, US
- Contact:
Rereading your request, I wonder if this is what you meant?
You have a script that performs a task using a text value that could change, that is the variable you mean.... Then define the variable in the script and pass the value to the variable on your command line to run the script
Sample Script,MyTest.scp:
Start the macro, these three lines will give you three different results:
MacroScheduler.exe /MyTest.scp /SearchValue=abc
MacroScheduler.exe /MyTest.scp /SearchValue=def
MacroScheduler.exe /MyTest.scp /SearchValue=ghi
(Oops, did not see reply from jpuziano that suggested three different scripts. This solution only requires one script, but must be started from different command lines or icons).
You have a script that performs a task using a text value that could change, that is the variable you mean.... Then define the variable in the script and pass the value to the variable on your command line to run the script
Sample Script,MyTest.scp:
Code: Select all
MessageModal>Seach value is %SearchValue%
MacroScheduler.exe /MyTest.scp /SearchValue=abc
MacroScheduler.exe /MyTest.scp /SearchValue=def
MacroScheduler.exe /MyTest.scp /SearchValue=ghi
(Oops, did not see reply from jpuziano that suggested three different scripts. This solution only requires one script, but must be started from different command lines or icons).
Hope this was helpful..................good luck,
Bob
A humble man and PROUD of it!
Bob
A humble man and PROUD of it!