Hello Guest it is April 16, 2024, 06:09:33 AM

Author Topic: Button to assign value to a variable  (Read 3820 times)

0 Members and 1 Guest are viewing this topic.

Button to assign value to a variable
« on: February 18, 2016, 03:11:34 PM »
hi i'm using mach 3 and I need to make some changes to my screen to assign a value to one variable on my GCODE instead of editing the value of the variable directly in the GCODE.
I was thinking to put un DRO and then on button thats take that value and set it to the variable [ with Setvar()]

Can anyone help me with the code??? ( i don't know how to get the data of the DRO and then properly assign the value to the variable)

thanks !
Re: Button to assign value to a variable
« Reply #1 on: February 18, 2016, 04:13:10 PM »
Hi,
 just playing with this idea.
Put a dro and a button on the screen
I used 1234 for example.
Put the script in the button.
Seem to work OK.
Re: Button to assign value to a variable
« Reply #2 on: February 18, 2016, 08:12:12 PM »
Thanks It's work OK !