LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to read cells in excel sheet while run time

Hi,
 
   Anyone have solution for my problem plz provide me ASAP.
 
Actually I want to open excel sheet,visible to user, from that excel sheet i need to select rows & columns,then stored into table in lab view.
IAnd one more thing then close the excel sheet.
 
 
Thanks & Regards
Anitha
0 Kudos
Message 1 of 19
(4,831 Views)

Hi Anitha,

this should help you http://zone.ni.com/devzone/cda/epd/p/id/2231

Mike

0 Kudos
Message 2 of 19
(4,826 Views)
Hi Mike,
 
   In this example defined the range;but i don't want like that.
For example first step open the excel sheet,visible to user,through hand i need to select from opened excel sheet,and stored into labview,then close the file.
 
Thanks & Regards
 
Anitha
0 Kudos
Message 3 of 19
(4,822 Views)

Hi Anitha,

if i understand you correct you want that the user select the Data stored in LabView manually, right? For that you can define a Callback function.

Mike

0 Kudos
Message 4 of 19
(4,819 Views)

Hi Mike,

  Yes ur right.How to do callback function,can you plz explain little bit clear.

Thanks & Regards

 

Anitha
0 Kudos
Message 5 of 19
(4,815 Views)
Hi Anitha,
there is a function to define callback functions in the ActiveX part of LabView. An example is available in the example finder. Search for callback. One of the examples is with Excel.
Mike
0 Kudos
Message 6 of 19
(4,814 Views)

Hi Mike,

  I don't want this way.For example in my excel sheet sunday,monday.....friday are stored in first colum.

Now in labview i opend that file with mouse i will place on sunday then that sunday automatically stored into labview .like that all one by one or all i need to store.

Thanks & Regards.

 

 

Anitha
0 Kudos
Message 7 of 19
(4,809 Views)
I'm sorry, but there's clearly a language issue here. What do you mean "automatically stored in LabVIEW"? Is it supposed to go into a table, a string indicator, a variable, ... ? Also, what does "like that all one by one or all i need to store" mean? Do you mean that if someone clicks on an individual cell then that cell's contents should be transferred to LabVIEW, or if the user selects a range then that range should be transferred to LabVIEW, or neither, or both?
0 Kudos
Message 8 of 19
(4,800 Views)

Hi Mike,

    If user clicks on an individual cell then that cell's contents should be transferred to LabVIEW & stored (table/string indicator/ variableor)& also if the user selects a range then that range should be transferred to LabVIEW.Both way I need.

Thanks & Regards

Anitha
0 Kudos
Message 9 of 19
(4,792 Views)

Hi Anitha,

i understand what you mean. Here is an example with the callback you need. To test it, create a new workbook or open an existing one and click into the cells.

Mike



Message Edited by MikeS81 on 04-03-2008 04:15 PM
0 Kudos
Message 10 of 19
(4,789 Views)