Jump to content

write in different sheet of csv file


K Waris

Recommended Posts

Hello All

I wonder if this is possible

I have a cluster of 3 arrays. I have easiy written the data of one array into csv file. I would like to write the data of other arrays written in

sheet 2 and sheet 3 of the csv file. 

 

I used simple open, close file function and write txt file function with the file path ending in .csv and it had worked fine. 

 

 

Best Regards

K.Waris

Link to comment

CSV is a flat file structure.  You can open it in notepad and see the data in the 2D format separated by commas and new lines.

 

CSV does not support a third dimension of data.  To store data in a way that Excel opens it and has multiple tabs you'll need a different file structure.  Using the Report Generation Toolkit you can have control over the file and save it as an XLSX which has support for worksheets (tabs).

 

Also you may be interested in generating a TDMS file using the build int TDMS write VIs.  NI then has a free add-in that opens TDMS in Excel and it also supports groups which is shown as workbooks when opened in Excel.

  • Like 1
Link to comment

If you use windows, there are examples in the Labview help on how to use the Excel ActiveX control, You can use different worksheets without much effort.

These examples also show how to fill a range of cells with a variant, which provide an elegant solution to your problem.

  • Like 1
Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.