Machsupport Forum

Mach Discussion => VB and the development of wizards => Topic started by: Aronne on September 23, 2019, 07:23:17 AM

Title: Saving VB-Scripts
Post by: Aronne on September 23, 2019, 07:23:17 AM
Hello,
trying to get familiar with Mach3 control (Demo Version R3.043.062), running sain smart 3018-mx3.
Testing the Auto Tool Zero procedure I got the right functionality. Now I would like to modify the script to get the right Z-position.
When I open the script from the button (Operator -> Edit button script), I get the code. I can modify it and let it run with good results. BUT when I try to save it, the system is resetting the file to it's original state and my modifications are lost !! I can modify the file from an external VB-editor, it works, but when I start the function from Mach3, it results the old script (Edit button script confirms this).

does anybody know if I'm doing stg wrong saving the script ??

cheers
Aronne
Title: Re: Saving VB-Scripts
Post by: Graham Waterworth on November 01, 2019, 07:48:57 PM
Remove the script from the button and put it in the M6Start.M1S macro for your selected profile.

Title: Re: Saving VB-Scripts
Post by: Aronne on November 09, 2019, 04:25:13 AM
Thank you for replying

I noticed that the zero-tool button always calls a VB-file called "HyddenScript..." (or similar), so I just copy the script with modifications to another file and AFTER CLOSING the Mach3 VB editor I rename the new file with "HyddenScript...". That works.
In addition I managed to set the zeroing on all the three axes :)

You say the M6Start.M1S macro is replacing the "HiddenScript..." one in a specific profile, so this is automatically called from that button ?

Have a great day
Aronne