Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / string to floatnumber?

Author
Message
Monzi
20
Years of Service
User Offline
Joined: 10th May 2004
Location: Denmark
Posted: 6th Apr 2005 08:03
Will A#=Val("2.0") put the real number in the A#? or will it be converted to an integer value?
Ric
20
Years of Service
User Offline
Joined: 11th Jul 2004
Location: object position x
Posted: 6th Apr 2005 13:02
It will be a real number. Don't even need the ".0" in this case.

To demonstrate, try

A#=Val("2")
print 3/2
print 3/A#
wait key

and you'll see.

Monzi
20
Years of Service
User Offline
Joined: 10th May 2004
Location: Denmark
Posted: 6th Apr 2005 18:48
Print Val("2.1") shows "2.09999911244"

why is that?

Login to post a reply

Server time is: 2024-09-23 17:28:15
Your offset time is: 2024-09-23 17:28:15