Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » zMUD General Discussion
millisa
Newbie


Joined: 17 Dec 2002
Posts: 7

PostPosted: Tue Dec 17, 2002 8:32 am   

Setting Carriage Returns in a Variable?
 
I'm trying to set some carriage returns in a variable and I'm having a little difficulty. Rather than showing the carriage return, it is showing the little box representation of a carriage return.

Ex.
TestVar=%concat( @TestVar, %cr, "New line")

Everytime I run that alias I would expect to get a new line in the variable 'TestVar'.
ie, I want:

New line
New line
New line

Instead it reads something like
(i'm using two square brackets to show the carriage return box)
New line[]New line[]New line

If I cut and paste that into something like this form, it translates the carriage returns right. Put it in notepad and it keeps the boxes. Is there another character I should be using to get these line feeds? (%char(10) has the same issue)
Reply with quote
Kjata
GURU


Joined: 10 Oct 2000
Posts: 4379
Location: USA

PostPosted: Tue Dec 17, 2002 3:31 pm   
 
Use %crlf:
TestVar=%concat(@TestVar, %crlf, "New line")

Kjata
Reply with quote
millisa
Newbie


Joined: 17 Dec 2002
Posts: 7

PostPosted: Tue Dec 17, 2002 8:42 pm   
 
Thanks! Thats what I wanted (just couldn't find mention of it in the help file).
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » zMUD General Discussion All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net