LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Is there any way to just read the excel worksheet name?

Hi

recently i just got this project need to read data from excel file, and after a few days of research i understand u can read and write to excel to  worksheet that the name or postion is known.

but is there any way to just read the excel worksheet name? As there excel format is not fixed and i need to search and open only the sheets i need.

I  try change it to string but dun seem to work.

not sure is this the right way... anyone?
Message 1 of 11
(9,382 Views)

Hi TomWang,

seet the attached picture, please. It shows how you can read all sheet names.

Mike

Message 2 of 11
(9,380 Views)
That great help!!! Thanks a lot. I can save some sleep time with it Smiley Very Happy


Message Edited by TomWang on 06-17-2008 04:39 AM
0 Kudos
Message 3 of 11
(9,368 Views)
Just one more question how did u got to the excel._worksheet with name?
my always gets excel.sheets with no option of Name... and i cant a way to change it...

I am still quite new to this... Smiley Indifferent


0 Kudos
Message 4 of 11
(9,362 Views)
nvm i got it... Thx... Mike...




Message Edited by TomWang on 06-17-2008 05:20 AM
0 Kudos
Message 5 of 11
(9,360 Views)
Now I can read the sheet name, but Can I modify the sheet name??
0 Kudos
Message 6 of 11
(9,234 Views)
Hi shiness.tw,
yes you can rename the sheet. The attached picture shows how.

Mike


Message Edited by MikeS81 on 07-05-2008 09:26 AM
Message 7 of 11
(9,226 Views)
In the Unbenannt1.PNG (33 KB) diagram, Varient to Data function.  How do you coerce the 'Type constant to 'Excel,_Worksheet when drawing diagram?
0 Kudos
Message 8 of 11
(8,953 Views)

There is nothing to coerce actually. Smiley Wink

 

First, create a constant ref for the prop node on the left-most. Then, del its wire & move it to the Variant to Data function & connect to it. Now, rt-click on the ref constant & choose Select ActiveX Class > Browse.. option. Select the Type Library as Microsoft Excel 11.0... & the Object as _Workbook.

 

Thats it, it ll automatically fetch you the Excel_Worksheet reference as the data. Smiley Happy

- Partha ( CLD until Oct 2024 🙂 )
0 Kudos
Message 9 of 11
(8,940 Views)

hi, it is a little older the subject, but I would like to add a new question. you can get the name of the sheet that are active in excel? that is, if I change my excel sheet manually, you can get the selected sheet since LabView? Thanks.

0 Kudos
Message 10 of 11
(4,307 Views)