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
 plot data into specified layer of hidden graph
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

uli_15

Germany
Posts

Posted - 02/06/2009 :  09:21:56 AM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Origin Ver. and Service Release (Select Help-->About Origin): 7.5
Operating System: Win XP

Hello,

I would like to plot data into a graph while the graph is not active.
That works, but if I have two layers in the graph and the last active layer was layer 2 I failed to select layer 1 and plot the data there.

Here is the code:

%N=Graph1; // graph with layer 1 and layer 2;
%k=n167; // the worksheet from which the column "nh" is to be plotted
%N!layer1.include(%k_nh);

So if before layer 2 of Graph1 was the active layer, the column "nh" is plotted into layer 2.
Searching the forum I found the command
range layer1 = [Graph1]1!;
but it did not change the result.

Can you tell me why and how to do it better?

Regards,
Uli


Deanna

China
Posts

Posted - 02/09/2009 :  01:39:03 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi
"range layer1 = [Graph1]1!;" only works for Origin 8.

For 7.5, would you please consider making layer 1 active before plotting? Just like in the following script:


%N=Graph1; // graph with layer 1 and layer 2;
%k=n167; // the worksheet from which the column "nh" is to be plotted
%N!Page.active = 1; //Make layer 1 active
%N!layer.include(%k_nh);


Deanna
OriginLab Technical Services
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