BUTTON question

Post Reply
User avatar
Jeff Barnes
Posts: 912
Joined: Sun Oct 09, 2005 1:05 pm
Location: Ontario, Canada
Contact:

BUTTON question

Post by Jeff Barnes »

Hi Everybody,

I am trying (without success) to manipulate a button.

I want to have a counter on the button and update it every time it is pressed.

This is an example:

@ 1,1 BUTTON oBtnLap PROMPT "LAP + ("+alltrim(str(nLapCounter))+")" SIZE 50,25 of oDlg1 FONT oFontSmall UPDATE Action (nLapCounter++, TONE(440,1),oDlg1:Update())

Can someone please help.

Thanks,
Jeff
User avatar
RAMESHBABU
Posts: 591
Joined: Fri Oct 21, 2005 5:54 am
Location: Secunderabad (T.S), India

Post by RAMESHBABU »

Mr.Jeff

Here is the solution.


@ 1,1 BUTTON oBtnLap PROMPT "LAP + ("+alltrim(str(nLapCounter))+")" SIZE 50,25 of oDlg1 FONT oFontSmall UPDATE Action (nLapCounter++, TONE(440,1),oBtnLap:SetText("LAP ("+alltrim(str(nCounter))+")")oBtnLap:Refresh())

Regards,

- Ramesh Babu P
User avatar
Jeff Barnes
Posts: 912
Joined: Sun Oct 09, 2005 1:05 pm
Location: Ontario, Canada
Contact:

Post by Jeff Barnes »

Thanks Ramesh

Works perfectly :)


Jeff
Post Reply