DIAdem

cancel
Showing results for 
Search instead for 
Did you mean: 

How to save tdm file from GPI extension DLL

Hi,
 
Is there any way to save data channels to tdm file format from GPI extension dll.
 
I've tried lDataSave function, but I get DAT file format.
 
I've also tried using Diadem.TOCommand interface, It'works with CmdExecuteASync method, but not with CmdExecuteSync (I've thought using a new thread with CmdExecuteASync, but what about synchronization ?).
 
As I need to run a process like, do something, save tdm file, then do another thing, I'm a little lost.
 
Thanks for any suggestion.
 
JMA.
 
0 Kudos
Message 1 of 2
(3,053 Views)
Hello!

First: I have no solution!

Second: Some remarks to using a OLE interface to DIAdem in GPI.

My experience is that there are only few situations and circumstances where it might be the only way to solve a problem. There are some critical things to know. If you create a ToCommand interface it isn't guaranteed that you get an interface to the proccess you are running in. In normal cases it will be but you can't be sure! CmdExecuteSync doesn't work because usually your command is initiated out of a script. While running a script DIAdem will not execute another command.
The problem with CmdExecuteASync is that the command will be put onto the DIAdem command stack. It will be executed after the script is finished. You can not be sure that the channel data is the same as it was at the time you called CmdExecuteASync. Multiple Calls to CmdExecuteASync will be executed after another.

Sorry that I do not have a solution but perhaps I can avoid some frustrating DIAdem-OLE-Test-Sessions.

Matthias
Matthias Alleweldt
Project Engineer / Projektingenieur
Twigeater?  
0 Kudos
Message 2 of 2
(3,039 Views)