The Origin Forum
File Exchange
Try Origin for Free
The Origin Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ | Send File to Tech support
Username:
Password:
Save Password
Forgot your Password? | Admin Options

 All Forums
 Origin Forum
 Origin Forum
 Filename and Path in the graph window
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

a_user

USA
0 Posts

Posted - 08/20/1998 :  7:45:00 PM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
I tried to put filename and path easy in the Graph using a text label
using %X%G, but I failed.
Now I found the reason: of course the path contains a lot of '\' and they
interpreted by in the text as control characters; so i see only 'f:'.
Is there an easy way to replace the '\' by '/' or to show them anyway?

Greetings

ACqua

Manfred Deicher

GERMANY
2 Posts

Posted - 08/20/1998 :  7:47:00 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Response

Use the command
label \v(%X&G)

This will display the "\" character

Manfred

Go to Top of Page

a_user

USA
0 Posts

Posted - 08/20/1998 :  7:55:00 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply

A clarification of text formatting

Origin uses escape sequences in a string that allow different ways of displaying text.
These sequences begin with the '\' character. All Text Objects (those created with the
Text Tool or the LabTalk label command) as well as text plotted from a Label
column will display according to the rules of these sequences. Here are some examples:

String

Some \b(bold) text

Some \c2(red) text

Some \i(italic) text

Appearance

Some bold text

Some red text

Some italic text

Display of a '\' character presents a problem. If an unsupported escape option or no
parenthesis follows the escape character, then the character(s) are ignored. Following
standard conventions, sequential '\\' will be interpreted as one '\':

String

C:\My Documents

C:\\My Documents

Appearance

C:My Documents

C:\My Documents

There is also the special notation to ignore escape sequences which Manfred Deicher
pointed out:

String

\v(C:\My Documents)

Appearance

C:\My Documents

Now we can look at Origin's ability to substitute the value of a string variable for
its name as well as LabTalks ability to generate text labels. In these examples, my Origin string variable percentY  is equal to D:\MYORIGIN50\:

note: due to a display problem with this post the word 'percent' is used rather than the symbol for percent. If you were using the notation in script, the symbol
for percent should be used.

LabTalk Command

label -n title1 My Origin is in percentY;

label -s -n title2 My Origin is in percentY;

label -s -n title4 My Origin is in \v(percentY);

Label displays as...

My Origin is in percentY

My Origin is in D:MYORIGIN50

My Origin is in D:\MYORIGIN50\

Note that the first label did not substitute the percentY with its value (D:\MYORIGIN50\). An additional command option (-s) was needed. This is
equivalent to turming on the 'Link to Variables' check box in the Label Control of a text
object. Once substituted, the text appeared, but without the '\' characters which required
the special \v() notation.

[Note: This message was edited by Julie]

Go to Top of Page
  Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000