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
 Make new workbook // If exists then skip making it
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

LaurP

Estonia
16 Posts

Posted - 11/29/2012 :  11:23:49 AM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Origin Ver. 9.0 and Service Release (Select Help-->About Origin): ? OriginPro
Operating System: Win7

I have wasted half a day finding a way how to do it, but I am not closer to the cause.

I need script that makes new worksheet if the named worksheet doesn't already exist. If it exists then it skips making it.

Have tried very much different ways and nothing works. HELP.

JacquelineHe

287 Posts

Posted - 11/30/2012 :  02:56:01 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi,

Please refer to the following example for adding the sheet1 in the Book1 if there is not a "sheet1" in the Book1.


win -a Book1;  //Active a workbook with short name Book1
if(exist("[Book1]sheet1!")==0)
{
  newsheet name:=sheet1;
}



OriginLab
Jacqueline
Go to Top of Page

LaurP

Estonia
16 Posts

Posted - 11/30/2012 :  06:36:48 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
kkk...


I didn't use " ".

THANKS!
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