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' command doesn't work properly
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

alkamid

Poland
27 Posts

Posted - 10/10/2010 :  06:10:00 AM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Origin Ver.: OriginPro 8 SR3
Operating System: Ubuntu 10.04 (wine)

Here's my script: http://paste.pocoo.org/show/273499/

It works properly when I copy it (the whole script) into the Script Window. However, if I try to run it by writing
run script.ogs

I get an error:
fname.GetToken(ii,CRLF)$: str expression error


Why? What should I do to be able to run the script with a single command?

Laurie

USA
404 Posts

Posted - 10/11/2010 :  10:27:05 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Please use "run.file(script.ogs);" instead of the run command. The run command executes line by line, so you'd need to put the open { on the same line as the loop command. The run.section() and run.file() object method provides greater flexibility for script file execution.



OriginLab Technical Support
Go to Top of Page

alkamid

Poland
27 Posts

Posted - 10/12/2010 :  04:41:37 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Thank you, it solved my problem.

Edited by - alkamid on 10/12/2010 04:42:03 AM
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