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
 All Forums
 Origin Forum for Programming
 LabTalk Forum
 LabTalk string(n-1) %[%Z,%[%Z]]

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

Screensize:
UserName:
Password:
Anti-Spam Code:
Format Mode:
Format: BoldItalicizedUnderlineStrikethrough Align LeftCenteredAlign Right Horizontal Rule Insert HyperlinkUpload FileInsert Image Insert CodeInsert QuoteInsert List
   
Message:

* HTML is OFF
* Forum Code is ON
Smilies
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Clown [:o)]
Black Eye [B)] Eight Ball [8] Frown [:(] Shy [8)]
Shocked [:0] Angry [:(!] Dead [xx(] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
peter.cook Posted - 07/01/2004 : 10:20:41 AM
Hi,

I've found this code :

%[%Z,%[%Z]] returns the string minus the last character. This is actually what I want. Is this expected behaviour with the script as shown ie reliable?

Cheers,

Pete

2   L A T E S T    R E P L I E S    (Newest First)
peter.cook Posted - 07/02/2004 : 4:52:39 PM
Hi Mike,

Thanks for clarification,

Cheers,

Pete

Mike Buess Posted - 07/01/2004 : 11:41:23 AM
Hi Pete,

%[%Z,n] returns the substring preceding the nth character.

n=%[%Z] is the number of characters in %Z.

So %[%Z,%[%Z]] should return the string minus the last character. (Labtalk indices start with 1.)

Mike Buess
Origin WebRing Member

The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000