LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

pass text messages to excel file

Dear Sirs:

I'm trying to communicate my LAB applicatiob with an excel file.

I have no problems to Read from excel or write to excel numeric values but I am having a lot of problemns to write in excel text messages.

For example:

In a text box I have the messagge " hello i am working "

How can I write this text box line in the A1 cell of excel worksheet?

And then How can I read from exce?

Best regards

Eneko
0 Kudos
Message 1 of 3
(3,306 Views)
Hi,

I have attached a file with some code I wrote to do several things using DDEServer functions. Also, here is a good website summarizing many Excel commands: http://techonthenet.com/excel/formulas/. Also, look in the CVI samples directory for activeX projects. Many of them are specifically for Microsoft application control.

Hope this helps
0 Kudos
Message 2 of 3
(3,284 Views)
It may be as simple as ensuring correct data type is specified.

For example I use the "Excel Report" function panel (..samples\activex\excel\excelreport.fp) and this line:

ExcelRpt_SetCellValue (ws_handle, cell, ExRConst_dataString, outstring);

So, having read the text box string into your character array "outstring", the above line should work. Note you need "ExRConst_dataString", not "ExRConst_dataDouble".

Hope this helps.
--Ian
0 Kudos
Message 3 of 3
(3,282 Views)