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
 All Forums
 Origin Forum for Programming
 LabTalk Forum
 Dialog showing up during script execution

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

Screensize:
UserName:
Password:
Anti-Spam Code:
Format Mode:
Format: BoldItalicizedUnderlineStrikethrough Align LeftCenteredAlign Right Horizontal Rule Insert HyperlinkUpload FileInsert Image Insert CodeInsert QuoteInsert List
   
Message:

* HTML is OFF
* Forum Code is ON
Smilies
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Clown [:o)]
Black Eye [B)] Eight Ball [8] Frown [:(] Shy [8)]
Shocked [:0] Angry [:(!] Dead [xx(] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
ob28130 Posted - 04/17/2025 : 07:22:28 AM
OriginPro 2018 (64-bit) SR1 - b9.5.1.195

Hello everybody, I'm trying to write a script that executes after an import. My purpose is to automatically plot several boxplots, starting from the data I import. I prepared an import filter to organise my data in the following order: the group column is column A in Sheet1 (the only sheet of the workbook at the moment of import), the data column for the first boxplot is in column D, that of the second boxplot is in column E, the third and fourth are respectively in column F and G. During the import I set the column A as being the X, containing text, B and C are labels and I won't use them for anything during the script, the remaining four columns are numeric Y. The following is my script:

string dataSheet$ = %H;
wks.col1.categorical.type=2;
wks.col1.categorical.sort=0;

plot_gboxindexed irng:=[dataSheet$]Sheet1!D group:=[dataSheet$]Sheet1!A theme:="Box_Data in Line" rd:=[<input>]<new name:="Voc">;
plot_gboxindexed irng:=[dataSheet$]Sheet1!E group:=[dataSheet$]Sheet1!A theme:="Box_Data in Line" rd:=[<input>]<new name:="Jsc">;
plot_gboxindexed irng:=[dataSheet$]Sheet1!F group:=[dataSheet$]Sheet1!A theme:="Box_Data in Line" rd:=[<input>]<new name:="FF">;
plot_gboxindexed irng:=[dataSheet$]Sheet1!G group:=[dataSheet$]Sheet1!A theme:="Box_Data in Line" rd:=[<input>]<new name:="PCE">;

Now, the problem is that right after the first plot_gboxindexed, a dialog shows up with the layer content for layer 1 and stopping the script from further executing. I don't understand how to solve the issue, how to stop that dialog from appearing and why it appears in the first place, since the infos it shows me do not require further modification for the boxplot to be the way I desire.

P.S. The script executes after all the files are imported even though there's only one file to import in my case.
Thank you for any suggesiton,
Alberto
2   L A T E S T    R E P L I E S    (Newest First)
YimingChen Posted - 04/23/2025 : 5:30:28 PM
Maybe you need to activate the workbook between each plotting. e.g.

plot_gboxindexed irng:=[dataSheet$]Sheet1!D group:=[dataSheet$]Sheet1!A theme:="Box_Data in Line" rd:=[<input>]<new name:="Voc">;
win -a %(dataSheet$); 
plot_gboxindexed irng:=[dataSheet$]Sheet1!E group:=[dataSheet$]Sheet1!A theme:="Box_Data in Line" rd:=[<input>]<new name:="Jsc">;
YimingChen Posted - 04/23/2025 : 5:27:25 PM
Does the script work on the worksheet with the data imported? Thanks.

James

The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000