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
 Run() Method for Graphic Objects
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

cdrozdowski111

USA
247 Posts

Posted - 01/06/2013 :  08:53:20 AM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
OriginPro 9.0.0 SR1, Win7 64-bit, running in VMware Fusion 5.0.2

I added a text label to a 1 layer graph. It is named METADATA_LABEL2 and is attached to the layer frame and has substitution level 1.
I added the following script to it (for testing) and set Script Run After to "none":

type -a test;

I cannot figure out how to "manually" run this script via labtalk. I have tried all of the following (with the graph active) in the command window (again, for testing) and none seems to work:


METADATA_LABEL2.Run();

Graph1!METADATA_LABEL2.Run();

GObject goMDL2 = METADATA_LABEL2; goMDL2.run();

GObject goMDL2 = "METADATA_LABEL2"; goMDL2.run();


What might I be doing incorrectly?

cdrozdowski111

USA
247 Posts

Posted - 01/06/2013 :  6:32:51 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Apparently, the script cannot be run via the Run() method unless it has been assigned to a Script, Run After event other than "None".

As a work-around, this appears to work:

GObject goMDL2 = "METADATA_LABEL2"; goMDL2.script = 1; goMDL2.Run(); goMDL2.script = 0;

Perhaps, this behavior can be changed in future releases.
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