LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

creating a excel file and saving data in it using ActiveX

Hi All
 
I am using LabVIEW 8.0. I want to write data in to excel file using ActiveX. When i am  writing in to a file which is created manully by me then it is writing perfectly.
I used in my VI Open/Create File function. So if the file is not present LabVIEW is creating a file for me. But i am not able to write data in to it. I set the property of the file as Read-Write only. Still it is not able to save in to the file.
 
Please help.
 
Thanks in advance.
Rikki
0 Kudos
Message 1 of 12
(8,910 Views)

Hi,

I would suggest to build up on a example "write table to excel.vi", which you will find with the NI Example Finder. This example is using activeX to write a table to excel, which shows the most common steps and also includes a good documentation.

BR, Christian

0 Kudos
Message 2 of 12
(8,906 Views)

Thanks Christian

I tried the write to table.vi which you have suggested me. It is creating the file and writing the data but when i again  try to write in to it it gives a message "File Existe do  you want to replace it" though i gave true to Save Changes as well as the file name when i am closing the workbook. Dont know the reason why it is asking for that.

Rikki

0 Kudos
Message 3 of 12
(8,892 Views)
Rikki,
 
Change the function to Create or Replace (for the Open/Create/Replace VI) and see if that works better for you.
Best regards,
Kalin T.
0 Kudos
Message 4 of 12
(8,863 Views)

Thanks for the reply.

I tried the same way as you told but the same problem.Please see the attached photo whether i am doing correctly or not.

Rikki

0 Kudos
Message 5 of 12
(8,856 Views)

Rikki,

See my previous message. You are still using Open or Create.
Best regards,

Kalin T.
0 Kudos
Message 6 of 12
(8,841 Views)
Thanks Kalin
 
The problem is solved. Thanks for your help.
 
Rikki
0 Kudos
Message 7 of 12
(8,814 Views)

Just for your information....

I tried that way also but was not able to do...

Rikki

0 Kudos
Message 8 of 12
(8,809 Views)

Hi,

 

I need to open and write into an existing excel worksheet that already has some function in it.  

The VIs attached (xls Test VI.vi) are doing this ok... but I have a message from excel saying if I want to replace it.  I have to click yes for the program to continue, but in the future we would want it to be automatic.  

 

Can anyone point out what could be modified in order to perform this action without input?

 

Thx

 

FB'

 

 

Message 9 of 12
(8,338 Views)

hi oneFrank,

i couldn't open ur file..i use labview 8.5.i had faced same problem,so if i could open ur file i can help u. can u send me file saved in 8.5 version?

 

Gaurav k
CLD Certified !!!!!
Do not forget to Mark solution and to give Kudo if problem is solved.
0 Kudos
Message 10 of 12
(8,312 Views)