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
 Copy short name

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
kdsaransh Posted - 12/16/2016 : 06:08:17 AM
HI

I want to copy the short name of 10 workbook into column A of another workbook named Book1. I am not able to do so. Pleas help....



Regards,
Rajesh Agarwal
3   L A T E S T    R E P L I E S    (Newest First)
cpyang Posted - 12/18/2016 : 11:11:55 AM
Don't know why, I used 2017 to test this code. Consider upgrade to current version.

Looks to me all the names are there, so you can also test for empty book name, not sure why it happened, like I said, 9.1 is very old version.

CP
kdsaransh Posted - 12/17/2016 : 11:47:21 AM
Thanks,

I have 9.1 version.

The output if the code is as shown in the picture. The 1st row do not have any data(1khz9). Also the name of the workbook in Book1 is not in sequence.

Any help.

Thanks again
Regards,

cpyang Posted - 12/17/2016 : 10:33:48 AM
This will do, assuming you have a recent enough version of Origin


range rn=[book1]1!col(a);
int ii=1;
doc -e W {
	string sB$=%H;
	if(sB.CompareNoCase("Book1")!=0)
	{
		rn[ii]$=sB$;
		ii++;
	}
}



CP

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