Notifications
Clear all

[Closed] button <name> ?

[left]how can I assign the value of a variable to the button[font=‘Courier New’] <name> ? [/font][/left]
[left] [/left]
[left]…[/left]
[left]var = “gngngn”[/left]
[left]…[/left]
[left]button theButton01 var pos:[10,116] width:106 height:12[/left]
[left]…[/left]
[left] [/left]
[left]thanks[/left]
[left]best regards[/left]
[left]paolo[/left]

2 Replies

Hi Paolo,
you can create an anonymous button then assign a tag to it on rollout open, or any other event you like, using the button.caption property.

rollout rol_Test "Test"
(
    local sCaption = "Push Me!"

    button btTest width:100 height:16 align:#center

    on btTest pressed do
    (
        btTest.caption = "Pushed!"
    )

    on rol_Test open do
    (
        btTest.caption = sCaption
    )
) -- End Rollout

createDialog rol_Test 108 26 200 300 style:#(#style_toolwindow, #style_border, #style_sysmenu)
  • Enrico

works perfectly!
thank you so much…
paolo