12-14-2006 02:54 PM
12-14-2006 03:12 PM
Hi Jeff,
I never knew about "PathNameGet" it does look ugly - I usually use a "FileNameGet" command and just take the return parameter, "FileDlgDir" to get the selected path. It looks like other Windows windows to me. For example, if I want a user to pick a path (and in this case, I have a default name for a file, if I would later create a file, but this doesn't really matter):
' --- Script starts here- --
If (FileNameGet("ANY", "FileWrite", "c:\", "NewFile") = "IDOk") Then ' Dialog closed with Ok
MsgBox FileDlgDir
End If
' --- Script ends here ---
Does this help any?
Julia
12-14-2006 03:18 PM
Hi Julia, thanks for the response. I'll have to try this.
I'm writing a script to batch-process a large number of DIAdem DAT files, converting each to CSV, so that our modeling team can import them into Matlab.
THis particular aspect of the script is ONLY selecting the destination DIRECTORY. I use your solution to get the filenames to convert. Didn't know I could return while only highlighting a folder, and not a file.
12-15-2006 01:18 AM
12-15-2006 07:19 AM
12-15-2006 09:22 AM
Hi Jeff,
There is no way to change the behavior of the DataPlugin, in this case the way it names the channels. What you can do is programmatically change the channel names with a DIAdem VBScript. You can also invoke the load process and use the MatLab DataPlugin all from the same VBScript, and you could even create a batch process to loop over a ton of files and do the conversion for each one.
Let us know which of the above you need help with,
Brad Turpin
DIAdem Product Support Engineer
National Instruments
12-15-2006 10:04 AM
12-18-2006 03:02 AM
12-18-2006 11:23 AM
Hi Jeff,
we have an example showing how a TDM file can be read in MatLab. If interested in this, please send an email to
Walter DOT Rick AT ni DOT com
Thanks
Stefan
05-11-2018 07:34 AM
Hi Brad,
It looks like the behavior of the MatLab plug-in hasn't changed over the years. I still get the filename prepended to the channel name in the MatLab output. (I'm converting datx to MatLab in this case.) I'm curious how I would change the channel names in the VBS script. If I re-open the mat file in DIAdem and remove the filename, it gets prepended back when I save it as a mat file. Am I missing something in the process?
Thanks,
Chris