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
 Code Builder does not execute LT script...

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
ivanovskikh Posted - 07/28/2011 : 6:59:45 PM
Origin Ver. and Service Release (Select Help-->About Origin): Pro 8.5.1
Operating System: Win XP SP3

Hi,

I have a strange problem. The Code Builder does not execute a very easy LT script at all. No reports about errors or anything wrong... just doing nothing!.. However, it works properly when I run it from the Script Window. Any other LT scripts run well from the Code Builder. Could anyone suggest what the problemis is? The script is below.

%A = %(page.comments$);
wcopy 1! 2!;
wks.name$ = "Normalized";
//normalizing data in sheet "Normalized"
rnormalize -r 2 irng:=1!Col(4) method:=max orng:="Normalized"!Col(4);
rnormalize -r 2 irng:=1!Col(5) method:=max orng:="Normalized"!Col(5);
rnormalize -r 2 irng:=1!Col(6) method:=max orng:="Normalized"!Col(6);
//plotting the normalized curves
plotxy iy:="Normalized"!(1,4:6) plot:=200 ogl:=[<new template:="DESY EMIS NM_CM-1" name:=Graph>];
string GraphName$ = %H;
layer.y.from = 0.00;
layer.y.to = 1.05;
//making label
page.active = 1;
label -j 2 -s -sa -n stamp "\b(n)\nT= K\n%A";
stamp.fsize = 14;
stamp.font=font(Times New Roman);
stamp.y = layer.y.to - stamp.dy / 1.5;
stamp.x = layer.x.to - stamp.dx / 1.5;
//legend
legendupdate mode:=custom custom:=@LL;
Legend.fsize = 12;
Legend.font = font(Times New Roman);
Legend.y = layer.y.to - legend.dy / 1.8;
Legend.x = layer.x.from + legend.dx / 1.8;

The script takes data from 3 last columns, normalizes them, put into new worksheet and plot graph.

The Origin and Code Builders are attached.

4   L A T E S T    R E P L I E S    (Newest First)
ivanovskikh Posted - 08/04/2011 : 5:47:43 PM
All the symbols seem to be good ones (ASCII)... I copied the script to Notepad and it doesn't show any strange characters. Anyway, the script works fine when run from the Script Window!...

Thanks!

Konstantin
cpyang Posted - 08/04/2011 : 10:03:11 AM
So it looks like your script has a character not being ASCII, you can try pasting that to notepad, or the script window, copy it and paste back to code builder command window.

CP
ivanovskikh Posted - 08/02/2011 : 02:08:59 AM
Hi,

Thanks for the comment!

"type -b hello;" works fine as well as any other scripts. The problem only with the script I showed above.
I switched ECHO =1. It returns some strange message to the script window. It appears as "r=?w". In fact the first simbol is not "r". It just looks like "r". When I copy the error message to the forum post it appers as "Ú=?w".

Again the script works fine when I put into the script window.

So, I cannot understand what is going on...
cpyang Posted - 07/30/2011 : 09:14:39 AM
First, try something simpler, like

type -b hello;

then, turn on error reporting by setting

echo=1;

and then the line with the error will show.

CP

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