LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Graph "get image" function to excel saving intermittently?

Solved!
Go to solution

Hi all,

 

I was looking for some help with an intermittent issue of saving a front panel image to excel.  There are two issues. 50% of the time it works fine but it also sometimes saves the default image instead of the updated image.

 

Process is as follows:

1.  create graph in subvi

2.  get image and save to temp jpg file locally

2. update front panel via reference

3.  Complete all other tests

4.  save all data including graph from temp jpg file to excel file

 

attached is the vi for saving the graph to excel

 

Thanks

0 Kudos
Message 1 of 6
(3,417 Views)

The above vi was not the one I wanted to post.  It works due to saving a graph everytime.  Attached is the vi that gets the data.

0 Kudos
Message 2 of 6
(3,415 Views)

Hi Bernie,

 

Do you have a data file to accompany this VI?  I'd like to take a look at it.

 

 

Regards,

Che T.
Applications Engineer
National Instruments
0 Kudos
Message 3 of 6
(3,390 Views)

Thanks for the reply Che,

 

I found the issue but need to find a workaround for it. 

 

The issue is that I used the Append Image to file from the report generation toolkit and it uses a link to the image.  So when I ran the next module it would update the temporary jpeg file and update it>  Since all the test records have the same link they would all have the latest graph inserted into the test record.  I also tried creating a new temp.jpg with new names for each module and updating the records and then deleting the temp.jpg when the test was done and it threw a 3rd party application error.

 

I am thinking active X might work.  Any suggestions for getting a jpeg file to embed into an excel test record permanently so I can move it with out worry from computer to computer????

0 Kudos
Message 4 of 6
(3,381 Views)
Solution
Accepted by BernieSAIC

In case anyone else runs into this problem:

 

I resolved the issue by creating a temporary folder and creating a new .jpg file inside with a new name (I used the DUT SN in this case) and import the image to the excel document.  I then delete this folder when the image is done being imported, thus forcing excel to keep the original data instead of being linked to the old jpeg.

I can now go on any computer on the network and have the same image inside the test record.  Before making this mod I could not open the file on the RT target machine and get the proper image.  Now I can...

0 Kudos
Message 5 of 6
(3,374 Views)

Hi Bernie,

 

Thank you for updating us with the workaround you found

 

 

Regards,

Che T.
Applications Engineer
National Instruments
0 Kudos
Message 6 of 6
(3,369 Views)