
-----------------------------------
nate
Thu May 01, 2003 3:36 pm

Formatting Text
-----------------------------------
There was a previous post almost about this topic but i wanna take it a step further.
I know how do make your program not crash if the user inputs more than 255 characters but how would you make it so that if the user only typed in (lets say 30 characters) it would delete the empty space. (which is not used)

ex.
var text :string (255)

get text : 255

put text..
put "blah"

If the user only typed in a 6 letter word, the next word blah appears on the next line. How do u prevent this from happening and still make the program not crash if user types 255 words
HELP ME

-Nate

-----------------------------------
Asok
Thu May 01, 2003 4:19 pm


-----------------------------------
var text :string (255) 

get text : 255 
cls
put text
locate (1,1+length(text))
put "blah" 

blah :P

-----------------------------------
nate
Thu May 01, 2003 6:47 pm

Dont' work for long strings
-----------------------------------
ASOK IT DOESN'T work when the string you enter is greater than 80 characters.

locate (x,y)
y can only go up 2 80

can you make it work for a longer string?!!!

-Nathan

-----------------------------------
Asok
Thu May 01, 2003 6:54 pm


-----------------------------------
This is the simpler way that I probably should've given you the first time

var text :string (255) 

get text : 255 
cls
put text ," blah"

-----------------------------------
nate
Thu May 01, 2003 7:45 pm

STILL DON:T WORK
-----------------------------------
IT STILL DOENS:T WORK, THAT WAY PUTS THE BLAH 1 Line below still.!! Try it out before you post it so that it works?

-----------------------------------
Asok
Thu May 01, 2003 9:04 pm


-----------------------------------
that puts it right after the text, if you want something else be more specific.
