01-22-2020 10:28 PM
In Diadem 2018, is there a way to export loaded data into an excel file with one sheet? I don't want to the root sheet to export.
Also, how do I export a link from a text channel in the portal that will show up as a clickable link in excel, any way to do that?
Thanks.
Solved! Go to Solution.
01-23-2020 11:40 AM - edited 01-23-2020 11:41 AM
Hi Russell,
There is a file export option in DIAdem 2018 that appears at the bottom right of the "File >> Save as..." dialog, in the list of all the read-write DataPlugins. This exports either the entire Data Portal contents or the selected elements of the Data Portal to a new *.xlsx file. However, it does so with a predetermined layout/schema, which you'll find familiar if you've ever loaded a TDM or TDMS file into Excel with the Excel Add-in. There is of course an option to do this programmatically as well.
The other option would be to programmatically connect to Excel via ActiveX and write individual cell values one by one or hand over cell ranges. This is also the only way to create native Excel items such as graphs or links. I haven't ever created an Excel link via ActiveX myself, but I'll bet it's possible.
I can help with the boilerplate ActiveX calls from a DIAdem VBScript to control Excel, but I have limited knowledge of the Excel ActiveX methods and properties available.
Brad Turpin
Senior Technical Support Engineer
National Instruments
01-23-2020 12:20 PM
I was hoping to avoid ActiveX, but if that's the only way, so be it.
There is an ActiveX example file in the Diadem help section. I will use that as reference.
Thanks!
01-23-2020 01:20 PM
Hi Russel Senior,
Have done quite a bit of ActiveX from DIAdem. Most things are possible, they just can be rather painful as well.
If you can get the Function you want to work in VBA with macro recording or just VBA then should be able to make a ActiveX do the same thing.
Paul