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
 Create User Defined Parameters
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

DrMK

Germany
12 Posts

Posted - 03/24/2020 :  06:37:42 AM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Origin 2019b (32-bit)
9.6.5.169
Copyright © 1991-2019 OriginLab Corporation
Windows 10

Hello,

i would like to create User Defined Parameters for selected Sheets in a workbook.

I found the option

wks.labels(*D1);

which works fine but it just creates a parameter for the active sheet.

Is there any possibility to create parameters in more selected sheets?

It would also work if there is a possibility to create them for all sheets in a book.

Thank you for your help!

Matej

DrMK

Germany
12 Posts

Posted - 03/24/2020 :  08:14:14 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
I found by myself a solution while testing some scripts.

With

loop (ii, 4, page.nlayers)
{page.active=$(ii); wks.labels(*D1); wks.UserParam1$ = "xxx"; };


I am creating for sheet 4 until last sheet (page.nlayers), for each sheet a parameter and rename it "xxx".






Matej
Go to Top of Page

YimingChen

1669 Posts

Posted - 03/24/2020 :  08:24:33 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi,

To run script on certain worksheet. try the following script:

layer -o [Book1]Sheet1 {
       wks.labels(*D1);
};


To loop all worksheets in current workbook and run the script:

doc -e LW {
	wks.labels(*D1);
}


James

Edited by - YimingChen on 03/24/2020 08:33:45 AM
Go to Top of Page

DrMK

Germany
12 Posts

Posted - 03/24/2020 :  10:03:57 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
quote:
Originally posted by YimingChen

Hi,

To run script on certain worksheet. try the following script:

layer -o [Book1]Sheet1 {
       wks.labels(*D1);
};


To loop all worksheets in current workbook and run the script:

doc -e LW {
	wks.labels(*D1);
}


James



Both works fine! Thank you!

Matej
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