Macros: A good thing when the situation is right!
Spire_Jeff
Formerly Caffeinated Programmer
I just had an occasion to use the Macros and it saved me a bunch of time! I needed to go through some old code and change it to use a function call to send data to the device instead of send_string. I was able to find replace the send_string dvDevice, and change it to fnSendString(. The problem was that I needed a ) on the end of the statement. I decided to try out the macro functionality because there were a lot of lines and I'm lazy 
I started recording. First, I did a find and remembered that someone said it worked better if you just typed in the string to find. I did that, then clicked find. Next I clicked close which left my cursor at the point it found something. I then did END to jump to the end of the line. Lastly I typed ) and finished the recording. I was a little shocked when I hit the play macro button and everything repeated properly! I then got excited and decided I had to post here.
It took a couple months, but I finally found a use for the macros. This is very reliant on being able to determine a definite series of key strokes to accomplish the task tho. It is also dependent on the format of the send_string commands in my case. I would have had to correct things had I split a send_string command over more than one line. The nice thing is that I was able to easily see what was done as I did it one step at a time and I was able to verify the correct changes were made.
Jeff
I started recording. First, I did a find and remembered that someone said it worked better if you just typed in the string to find. I did that, then clicked find. Next I clicked close which left my cursor at the point it found something. I then did END to jump to the end of the line. Lastly I typed ) and finished the recording. I was a little shocked when I hit the play macro button and everything repeated properly! I then got excited and decided I had to post here.
It took a couple months, but I finally found a use for the macros. This is very reliant on being able to determine a definite series of key strokes to accomplish the task tho. It is also dependent on the format of the send_string commands in my case. I would have had to correct things had I split a send_string command over more than one line. The nice thing is that I was able to easily see what was done as I did it one step at a time and I was able to verify the correct changes were made.
Jeff
Leave a Comment
Categories
- All Categories
- 2.5K AMX General Discussion
- 922 AMX Technical Discussion
- 514 AMX Hardware
- 502 AMX Control Products
- 3 AMX Video Distribution Products
- 9 AMX Networked AV (SVSI) Products
- AMX Workspace & Collaboration Products
- 3.4K AMX Software
- 151 AMX Resource Management Suite Software
- 386 AMX Design Tools
- 2.4K NetLinx Studio
- 135 Duet/Cafe Duet
- 248 NetLinx Modules & Duet Modules
- 57 AMX RPM Forum
- 228 MODPEDIA - The Public Repository of Modules for Everyone
- 943 AMX Specialty Forums
- 2.6K AMXForums Archive
- 2.6K AMXForums Archive Threads
- 1.5K AMX Hardware
- 432 AMX Applications and Solutions
- 249 Residential Forum
- 182 Tips and Tricks
- 146 AMX Website/Forums