Button name
Moderators: TomKerekes, dynomotion
Button name
Hi! Is it possible to change the inscription on the button executing the script from the script?
This is needed to get the status indicator.
Regards, Taras!
This is needed to get the status indicator.
Regards, Taras!
- TomKerekes
- Posts: 2677
- Joined: Mon Dec 04, 2017 1:49 am
Re: Button name
I don't fully understand.
But here is a screen with Button (IDC_But10) labeled Change which changes the text of IDC_But11 by executing a SubScript (Change Text).
Note when the text of a button is changed the screen may not update with the new text until the button is redrawn. We should probably add a command to re-draw it. The SubScript sets the focus to the button to cause it to be redrawn.
Note you must remove the .txt extensions.
HTH
But here is a screen with Button (IDC_But10) labeled Change which changes the text of IDC_But11 by executing a SubScript (Change Text).
Note when the text of a button is changed the screen may not update with the new text until the button is redrawn. We should probably add a command to re-draw it. The SubScript sets the focus to the button to cause it to be redrawn.
Note you must remove the .txt extensions.
HTH
- Attachments
-
- ChangeText.scr.txt
- (240 Bytes) Downloaded 101 times
-
- WithChangeText.scr.txt
- (54.49 KiB) Downloaded 98 times
Regards,
Tom Kerekes
Dynomotion, Inc.
Tom Kerekes
Dynomotion, Inc.
Re: Button name
Thanks Tom for the quick response. Can I do it from C program ?
I want to turn on and off RTCP one button and so that the name of this button changes RTCP_on and RTCP_off.
So I will know what mode the machine is in now.
Regards, Taras!
I want to turn on and off RTCP one button and so that the name of this button changes RTCP_on and RTCP_off.
So I will know what mode the machine is in now.
Regards, Taras!
- TomKerekes
- Posts: 2677
- Joined: Mon Dec 04, 2017 1:49 am
Re: Button name
Hi Taras,
Did you mean change the Text of a label (not the name of button)?
Did you mean change the Text of a label (not the name of button)?
Regards,
Tom Kerekes
Dynomotion, Inc.
Tom Kerekes
Dynomotion, Inc.
Re: Button name
Hi Tom. Maybe you're right. See screenshot. Is there access to this component from a C program?
Regards, Taras!
Regards, Taras!
- TomKerekes
- Posts: 2677
- Joined: Mon Dec 04, 2017 1:49 am
Re: Button name
Hi Taras,
Those are buttons. Why not use a Label using the KMotionCNC Screen Editor?
Those are buttons. Why not use a Label using the KMotionCNC Screen Editor?
Regards,
Tom Kerekes
Dynomotion, Inc.
Tom Kerekes
Dynomotion, Inc.
Re: Button name
Hi Tom.You did not understand me. I need to change the text on a button to hot. During work KMotionCNC.
I want to turn on and off the RTCP with one button and also so that the name of the button changes as in the pictures below.
Regards, Taras!
I want to turn on and off the RTCP with one button and also so that the name of the button changes as in the pictures below.
Regards, Taras!
- TomKerekes
- Posts: 2677
- Joined: Mon Dec 04, 2017 1:49 am
Re: Button name
Hi Taras,
Ok so you do want it to be a button.
I was making changes to make that possible/easier but ran into a problem. To turn on RTCP ie:
G43.3 Hn
Which tool needs to be specified. How would you handle that? I suppose we could remember the last Tool loaded via M6 Tn Tool change. Do you have any suggestion?
Ok so you do want it to be a button.
I was making changes to make that possible/easier but ran into a problem. To turn on RTCP ie:
G43.3 Hn
Which tool needs to be specified. How would you handle that? I suppose we could remember the last Tool loaded via M6 Tn Tool change. Do you have any suggestion?
Regards,
Tom Kerekes
Dynomotion, Inc.
Tom Kerekes
Dynomotion, Inc.
Re: Button name
Hi Tom. When changing the tool, it can be indicated as in the screenshot. When RTCP is turned on, take the tool number from the active one.
Sorry for my English.
Regards, Taras
Sorry for my English.
Regards, Taras
Re: Button name
I also noticed this problem. If RTCP is turned off and I turn it on G43.4H1, the position of the Z axis becomes - the length of the tool. If this happens during the execution of the G code, then the zero of the workpiece will move lower by the length of the cutter and machining will continue above the workpiece. Is this normal behavior Tom? I think that when the RTCP is turned on, the length of the tool should be recorded in offset without affecting the height of the Z axis.KMotionCNC Version 4.35F .
Regards, Taras.
Regards, Taras.