| T O P I C R E V I E W |
| 31922A |
Posted - 07/10/2006 : 09:44:37 AM Origin Version (Select Help-->About Origin): 7.5 Operating System: Win XP
I'm trying to pass the names of the Origin worksheets into Labview. I'm using the labtalk function pe_dir("*","w"). I'm able to execute the labtalk script from labview and the command returns a list of origin worksheets to the origin script window but how can I get this list into labview?

Thanks in Advance.
Nick Argyros nicka@idinet.com |
| 2 L A T E S T R E P L I E S (Newest First) |
| 31922A |
Posted - 07/10/2006 : 5:12:44 PM That works great.
Thanks for the help.
Nick Argyros nicka@idinet.com |
| easwar |
Posted - 07/10/2006 : 4:14:52 PM Hi Nick,
What the pe_dir command (which is a script command that was implemented/added in 7.5 using an Origin C function - you can see the function in LT_pe.c file in Code Builder System tree) is to just print the window names to script window. The names are not saved in a string, they are just printed, and so you cannot "get" them from LavbVIEW.
You could instead pass the following script command using the OAExecute method: %z="";doc -e W {%z=%z %h;}; This would use the doc LabTalk command to loop thru all worksheets and the names get added to the string %z So %z in the end will contain a string such as "Data1 Data2 Data3..."
Then you can use the OAGetLTStr subVI in the Origin subVI collection to "get" the contents of %z into a LabVIEW string variable and do string parsing at the LabVIEW end to get the names.
If this does not suit your needs, please post again and specify what you are trying to acheive and we can think of perhaps a better solution.
Easwar OriginLab
|