Community
AutoCAD Forum
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Carriage Return in Script

3 REPLIES 3
Reply
Message 1 of 4
MachineHum
2370 Views, 3 Replies

Carriage Return in Script

Hey guys,

 

I'm trying to incorporate a CR into a script. I've look around and people have said either \P or \X, this does'nt seem to be working... this is the script:

 

text
j
TL
7.375,0.625
0
LINE1\PLINE2

 

This is the output:

 

Capture.JPG

3 REPLIES 3
Message 2 of 4
pendean
in reply to: MachineHum

-MTEXT instead of TEXT may be the cure, explore it afterwards if youo just want single text lines (all in the same scr file).
Message 3 of 4
Kent1Cooper
in reply to: MachineHum

The end of a line in a Script file is a carriage return.  The trick here is to understand the difference between the way the Text command works in a Script, like the way-back mid-1980's original Text command, and the way it has worked "live" in AutoCAD for years now, which is like what was called Dtext when it first appeared, but now the regular Text command works Dynamically that way.  The way it works in a Script, you must type the first line, hit Enter [#1] and that is registered, hit Enter again [#2] to recall the Text command, and hit Enter yet again [#3] when it's asking for an insertion point, to say "I want another line under the one I just wrote," and then type the contents of the next line, with a final Enter at the end to register that string.

 

text
j
TL
7.375,0.625
0
LINE1

 

 

LINE2

 

 

Two blank lines between the two strings constitutes those three Enters altogether, counting the one at the end of LINE1.  And make sure it all ends with an Enter, too [if you hit Ctrl+End when in the .scr file, the cursor must go below the LINE2, not at the end of it].

Kent Cooper, AIA
Message 4 of 4
MachineHum
in reply to: Kent1Cooper

Thankyou so much!

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report

”Boost