· String to Real

How can I do this:

Realvar:= Edit1.Text; ( StrToInt doesn't work )

and viceversa.

bryan
LVL 3
bryan7Asked:
Who is Participating?
 
ZifNabConnect With a Mentor Commented:
yo bryan,

RealVar := StrToFloat(Edit1.Text);

viceversa FloatToStr or FloatToStrF

Regards, Zif.
0
 
kretzschmarCommented:
hi bryan7,

an other solution is to use the Val-Procedure

Val(Edit1.Text,RealVar,ErrorCode)

meikl
0
 
bryan7Author Commented:
thanx
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.