| T O P I C R E V I E W |
| wallacej |
Posted - 06/14/2005 : 05:08:07 AM Origin Version (7.5): Operating System: win2K
Hi
I have a LabTalk script which generates a report containing graphs etc. The problem: Part of the way through the report generation the script halts and does not continue until the user moves the mouse or hits a key on the keyboard. I am finding this particularly baffling because the problem occurs on only one of 8 PC's using the same script.
The script halts just before a window is displayed allowing the user to import an image, here is that section of script:
label -d 930 610 -s -n date %M %L %O; system.font.labelSize = 22; // change back to normal font size after auto text insertion
//Open browse window for user to select an image run.section(imgfile,ImportImage); if( BMP1.Width!=0/0 ) { //test condition for existence of image (has user clicked cancel?) BMP1.Width = 1850; BMP1.Height = 1844; BMP1.Left = 4554; BMP1.Top = 2668; }
Any ideas why?
Thank You in advance
Wallace
|
| 4 L A T E S T R E P L I E S (Newest First) |
| Mike Buess |
Posted - 07/26/2005 : 10:50:31 AM Glad you caught the typo. I'd hate to think I was the cause of your problems. 
Your script at the top draws a label before invoking the file dialog. Does that label appear before the "pause"? (Perhaps the problem occurs before the imgfile script.)
Mike Buess Origin WebRing Member |
| wallacej |
Posted - 07/26/2005 : 08:41:30 AM Hi Mike
Yes the modification to the imgfile.ogs file is on every system. however I did not include the double semicolon because I assumed that it was a typo.
Also, I ran a search and the imgfile.ogs file is located in the OriginPro75 directory only. I have compared the file from a problem PC and a working PC and they are identical. Do you have any more suggestions? My only thoughts were further files called from the imgfile.ogs file but I cannot see anything.
Thank You
Wallace
|
| Mike Buess |
Posted - 07/25/2005 : 3:59:08 PM Hi Wallace,
Your reference to imgfile.ogs rang a bell so I located one of your earlier posts in which I suggested two alternative modifications to the [ImportImage] script section...
http://www.originlab.com/forum/topic.asp?TOPIC_ID=3981
Was the first suggestion incorporated on any of the problem PCs? If so, I see a potential problem in the following loop...
for(i=1;i>0;i++) { %A=%[%Z,#i]; if(%A=="") break; if(%A!="JPG") %L=%L %A;; // double semicolon!! }
Double semicolons can have unpredictable results so I suggest you remove the extra semicolon where noted. Just a hunch, but maybe worth checking out.
...And don't forget to look for imgfile.ogs on the User path. If you distribute your tools via OPK and included a modified version of the file then it would end up in the User Files folder. That would explain why the version in the program folder was unchanged.
Mike Buess Origin WebRing Member
Edited by - Mike Buess on 07/25/2005 4:26:57 PM |
| wallacej |
Posted - 07/25/2005 : 12:12:37 PM Hi
I've been asked to look at this problem again and I have a bit more information.
As I stated I have several machines with this script running. I noticed that only machines with SR 2 have the problem (SR 2 is the lowest release that I have), the other systems on SR 4 do not have the fault.
I updated one of the machines from SR2 to SR5 but this did not resolve the issue.
My thoughts are that there is a bug somewhere in the script that has been resolved after SR2 but maybe I have modified the file containing the bug which means that it was not updated during the deployment of the patch. I have thoroughly compared the file imgfile.ogs (which i have modified) and it is identical on both systems with SR 2 and SR 4.
I hope that this information may trigger some ideas.
Thank You
Wallace
|