The Daily Click ::. Forums ::. Klik Coding Help ::. Setting Global Value using a Edit Text Box
 

Post Reply  Post Oekaki 
 

Posted By Message

JulianHaines



Registered
  27/11/2004
Points
  3
23rd December, 2004 at 18:38:19 -

Hi,

A very simple question but I can not figure it out, I am trying to set a number global value using a text edit box, I and adding an event "edit box has just been modified" then change global value but it says number value only..
How is it done.

Thanks for your help

Joolz

 
JOOLZ

ChrisB

Crazy?

Registered
  16/08/2002
Points
  5457
23rd December, 2004 at 20:02:12 -

Use the Val( ) expression to convert the text returned by the Edit box into a number.

 
n/a

David Newton (DavidN)

Invisible

Registered
  27/10/2002
Points
  8322

Honored Admin Alumnus
23rd December, 2004 at 21:13:15 -

Yes, use Val(Edittext$("Edit Object")) - many people have difficulty getting values/strings from Edit boxes, as you can't get them directly using an action on the object, instead having to get a value from it.

 
http://www.davidn.co.nr - Games, music, living in America

Long John Kickbag



Registered
  26/08/2002
Points
  148
23rd December, 2004 at 22:20:12 -

Uh... Edit box>Get numeric value (or Edit Value("Edit"))...

 
Resize! - www.clicksplat.com/comparison.html

Tigerworks

Klik Legend

Registered
  15/01/2002
Points
  3882
24th December, 2004 at 08:53:40 -

Val(Edittext$("Edit Object")) can return floats such as 1.5.
Edit Value("Edit object") (found via Get Numeric Value) cannot return floats, everything will be rounded to 1, 2, 3 etc.

 
- Tigerworks
   

Post Reply



 



Advertisement

Worth A Click