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
 How to manipulate the name of objects

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
elfine Posted - 11/14/2008 : 07:29:46 AM
dear sir,
I want to compare the name of a object,for example,a worksheet with a string that comprises of a wildcard.
I want to use this kind of sentence like "if(%H=="data*")" where "*" denote a wildcard .But I can't make it working.
Could you please help me ?
Thank you !
4   L A T E S T    R E P L I E S    (Newest First)
elfine Posted - 11/17/2008 : 01:05:56 AM
Thanks a lot!

quote:
Originally posted by cpyang

Time to get Origin 8 :)

LabTalk string variable was added in Origin 8, together with all the new functions. Origin 7.5 only has string registers %A-%Z.

CP


cpyang Posted - 11/16/2008 : 8:01:14 PM
Time to get Origin 8 :)

LabTalk string variable was added in Origin 8, together with all the new functions. Origin 7.5 only has string registers %A-%Z.

CP
elfine Posted - 11/15/2008 : 8:24:58 PM
Thank your kind help!
I use the Origin 7.5 version.
When I type

name=%H;
name=;

It returns

NAME=--

What is the problem ?
quote:
Originally posted by cpyang

Assuming you are using Origin 8, then

string name=%H;
if(name.Match("Book*"))
type yes;
else
type no;

See this link for LabTalk string variables:

http://wiki.originlab.com/~originla/wiki/index.php?title=LabTalk:String_%28object%29#Match


CP


cpyang Posted - 11/14/2008 : 7:20:36 PM
Assuming you are using Origin 8, then

string name=%H;
if(name.Match("Book*"))
type yes;
else
type no;

See this link for LabTalk string variables:

http://wiki.originlab.com/~originla/wiki/index.php?title=LabTalk:String_%28object%29#Match


CP

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