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.

Author
Message
Suzaku
19
Years of Service
User Offline
Joined: 1st Dec 2004
Location: I have no idea
Posted: 3rd Feb 2005 02:24
How can i make a dimmed variable equal to the value of a part of a string?
Mobiius
Valued Member
21
Years of Service
User Offline
Joined: 27th Feb 2003
Location: The Cold North
Posted: 3rd Feb 2005 02:25
Integer = Val(String$)

Val will return the numeric value of a string.

(E.G. Val("100") gives you 100)

1800+ XP - GeforceFX 5600 - 256MbDDR - 60Gb Hdd - XP Pro (SP2)
Dodo
20
Years of Service
User Offline
Joined: 8th Aug 2004
Location: eating lunch
Posted: 3rd Feb 2005 04:35
if you're looking to break up the string, then use left$, right$ and mid$.

Part of solving the problem is actually noticing that the problem is there in the first place

Ric
20
Years of Service
User Offline
Joined: 11th Jul 2004
Location: object position x
Posted: 3rd Feb 2005 06:15
And if I don't say it, somebody else will ..... try to be a little more thoughtful/polite with your subject headings.


Suzaku
19
Years of Service
User Offline
Joined: 1st Dec 2004
Location: I have no idea
Posted: 5th Feb 2005 04:01
Quote: "if you're looking to break up the string, then use left$, right$ and mid$.
"

Can somone please explain left$, right$ and mid$ to me please.
Mr Pointless
20
Years of Service
User Offline
Joined: 17th Oct 2004
Location: Stuck in the UK
Posted: 5th Feb 2005 04:11
Left$(String, Number)

This'll return the first so-many characters of a string. How many letters depends on the number you specify

e.g. left$("SpaceMonkey",5) would return "Space"

Right$ does the same, but returns the last so-many characters.

Mid$ is different. It only returns a single character.

e.g. mid$("SpaceMonkey",6) would return "M".

Any wiser?

Originality is not dead, it just has an annoying tendency to fall asleep without setting the alarm clock
Suzaku
19
Years of Service
User Offline
Joined: 1st Dec 2004
Location: I have no idea
Posted: 5th Feb 2005 04:27
Thanks, you don't know how much that helps me!
Mr Pointless
20
Years of Service
User Offline
Joined: 17th Oct 2004
Location: Stuck in the UK
Posted: 5th Feb 2005 04:41
Welcome.

Originality is not dead, it just has an annoying tendency to fall asleep without setting the alarm clock

Login to post a reply

Server time is: 2024-11-27 21:25:20
Your offset time is: 2024-11-27 21:25:20