forum.vdsworld.com Forum Index forum.vdsworld.com
Visit VDSWORLD.com
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


Help please with radio buttons

 
Post new topic   Reply to topic    forum.vdsworld.com Forum Index -> General Help
View previous topic :: View next topic  
Author Message
gbzstro
Newbie


Joined: 15 Dec 2002
Posts: 3

PostPosted: Mon Dec 16, 2002 3:45 pm    Post subject: Help please with radio buttons Reply with quote

Hello - I am a newbie to VDS and I am looking for some help twith the radio buttons

all I want to do is set a varible %M when ever a radio button is selected - but I can not get it to work Embarassed

Thanking you all in adavnce

Title Radio
DIALOG CREATE,New Dialog,-1,0,240,160,
DIALOG ADD,RADIO,Type,39,120,80,72,Caption,Advisory|Watch|Warning,,CLICK
DIALOG SHOW
:Evloop
wait event
goto @event()

:TypeCLICK
rem read what radio Button was clicked and set %M with avisory,Watch or Warning
%M = What value was clicked ???
info %M

goto Evloop



:Close
exit
Back to top
View user's profile Send private message
LiquidCode
Moderator Team


Joined: 05 Dec 2000
Posts: 1753
Location: Space and Time

PostPosted: Mon Dec 16, 2002 3:48 pm    Post subject: Re: Help please with radio buttons Reply with quote

All you need to do is use the @dlgtext() function. Like this:

Code:

Title Radio
  DIALOG CREATE,New Dialog,-1,0,240,160,
  DIALOG ADD,RADIO,Type,39,120,80,72,Caption,Advisory|Watch|Warning,,CLICK
  DIALOG SHOW
:Evloop
  wait event
  goto @event()

:TypeCLICK
rem read what radio Button was clicked and set %M with avisory,Watch or Warning
%M = @dlgtext(Type)
info %M
goto Evloop



gbzstro wrote:
Hello - I am a newbie to VDS and I am looking for some help twith the radio buttons

all I want to do is set a varible %M when ever a radio button is selected - but I can not get it to work Embarassed

Thanking you all in adavnce

Title Radio
DIALOG CREATE,New Dialog,-1,0,240,160,
DIALOG ADD,RADIO,Type,39,120,80,72,Caption,Advisory|Watch|Warning,,CLICK
DIALOG SHOW
:Evloop
wait event
goto @event()

:TypeCLICK
rem read what radio Button was clicked and set %M with avisory,Watch or Warning
%M = What value was clicked ???
info %M

goto Evloop



:Close
exit

_________________
Chris
Http://theblindhouse.com
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Hortalonus
Valued Contributor
Valued Contributor


Joined: 15 Mar 2002
Posts: 344
Location: Western USA

PostPosted: Mon Dec 16, 2002 3:50 pm    Post subject: Reply with quote

The @DLGTEXT() function will return the radio element selection.

Code:
Title Radio
DIALOG CREATE,New Dialog,-1,0,240,160,
DIALOG ADD,RADIO,Type,39,120,80,72,Caption,Advisory|Watch|Warning,,,CLICK
DIALOG SHOW
:Evloop
wait event
goto @event()

:TypeCLICK
rem read what radio Button was clicked and set %M with avisory,Watch or Warning
%M = @DLGTEXT(Type)
info %M

goto Evloop



:Close
exit
Back to top
View user's profile Send private message Send e-mail
Hortalonus
Valued Contributor
Valued Contributor


Joined: 15 Mar 2002
Posts: 344
Location: Western USA

PostPosted: Mon Dec 16, 2002 3:53 pm    Post subject: Reply with quote

Oooops! Looks like you beat me to it Chris! Embarassed
Back to top
View user's profile Send private message Send e-mail
gbzstro
Newbie


Joined: 15 Dec 2002
Posts: 3

PostPosted: Mon Dec 16, 2002 3:58 pm    Post subject: Reply with quote

Thank you both for the quick responce this has worked a treat
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    forum.vdsworld.com Forum Index -> General Help All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum

Twitter@vdsworld       RSS

Powered by phpBB © 2001, 2005 phpBB Group