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 for Programming
 LabTalk Forum
 how to access column of worksheet create by script
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

elfine

China
9 Posts

Posted - 10/15/2009 :  12:53:33 AM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Origin Ver.8.0

Hello,everyone!

I want to process some data and I have a incomplete program here.

getfile -g i;
strpath$="%A";
fname$ = strpath.GetFileName(2)$;
if(fname.Match(ief$))
{%B=ief$;
win -t wks origin %B;
open -w %A;

bef$=ief$;
bef.replace("ief",bef);
%B=bef$;
win -t wks origin %B;

Then I want to copy the col(b) of worksheet named ief$ to col(b) of worksheet named bef$,but I don't know how to access the two worksheets and the two columns.

Best regards!

larry_lan

China
Posts

Posted - 10/16/2009 :  02:54:03 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi:

Better to use range variables to hold your worksheet and columns. And from Origin 8, we supports multiple worksheets in a workbook. Suppose ief$ and bef$ holds the workbook name and both have one worksheet named "sheet1", you can run:

range ra = [ief$]sheet1!col(b);
range rb = [bef$]sheet1!col(b);
rb = ra;


For more about range notation, please read our LabTalk Programming Help.

Thanks
Larry
OriginLab Technical Services
Go to Top of Page

elfine

China
9 Posts

Posted - 10/17/2009 :  01:40:35 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Thanks a lot!
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