LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Read data using google spreadsheet data API

Hi!

Does any one please have an idea about how to resolve this error, I found error 1 linked to invoke node in Query.VI. ( see the screeshot below) I know that when having this error, it means that there is an invalid input parameter. however, I checked and there is no unallowed imput !

please could you check the Query VI with me to find where is the error?

thank you in advance 

code d'erreur 1.PNG

0 Kudos
Message 12 of 22
(1,569 Views)

@Student_LV wrote:

 

please could you check the Query VI with me to find where is the error?


There is nothing for us to check! We can't put probes on images, and all the inputs seem to be set outside this VI.

 

I'd think the problem lays in another VI (GetBooks.vi maybe?), as Query.vi is just a generic sub VI (don't shoot the messenger: Query.vi is just where the error is reported).

0 Kudos
Message 13 of 22
(1,563 Views)

Hi! 

Thank you for your response. You will find attached the vi "google documents read"; Could you please check with me the error is due to what ,in GetBooks.VI.( sub vi Query )

0 Kudos
Message 14 of 22
(1,561 Views)

Pretty sure that code is just the example code. It has nothing specific for your application. As the problem is in your application, there is not much we can do... This code has been used before, so the problem is in how you use it. Without telling us how you use it, it will be hard for us to say anything about the problem.

0 Kudos
Message 15 of 22
(1,548 Views)

In fact, I aim to read data from .XLSX files into LabVIEW, I want to have the content of each sheet in an array.

((Microsoft excel is not installed in the target PC ( so Active X and 3rd part XLR8 are eliminated ) , i don't want also to pass through conversion to other types of file (such as .CSV or XML)))

So the only workaround solution that i've found is to use google spreadsheets data API.net.

I found the example, that i attached previously, in one of the forum discussions, developped by a LV user. After Installinf the .NET Google Data API, we should authenticate to Google Doc account by entring username and password, then enter book name and sheet name to get the data in each spreadsheet. I entred all the information but I always get nothing in return.

So, how can I make this code useful following my need?  as it's the ultimate solution for me after too many trials done on this code, (especillay that the other manners suggested above are not applicable in my case) 

Thank you in advance 

 

0 Kudos
Message 16 of 22
(1,541 Views)

So you want to read a locally stored *.xlsx file (Microsoft Excel type) and you do not have installed Microsoft Excel. 

Then you try to use a online cloud service (Google) to read the file? 

Are the file uploaded to Google Sheet for the given account that you have entered in the API? 

0 Kudos
Message 17 of 22
(1,533 Views)

@dkfire wrote:

So you want to read a locally stored *.xlsx file (Microsoft Excel type) and you do not have installed Microsoft Excel. 

Then you try to use a online cloud service (Google) to read the file? 


It's a mystery to me too...

 

I've looked for this a few times myself, and I never even saw Google spreadsheet API being mentioned. Google must be different then mine...

 

https://www.google.com/search?q=free+xlsx+.net+library:

https://stackoverflow.com/questions/151005/create-excel-xls-and-xlsx-file-from-c-sharp

https://stackoverflow.com/questions/15990871/any-open-source-free-library-for-handling-excel-both-xl...

https://code.google.com/archive/p/excellibrary/downloads

 

I have no idea if Google's API can do that or how.

 

Still, without having the same setup and code, we can't reproduce the error.

 

0 Kudos
Message 18 of 22
(1,525 Views)

Hi!

I thank you for your responses

Yes I want to read *.xlsx file, without having Microsoft Excel installed, and the file is already existing as a google spreadsheet in the account that I entred in the API,   

For thesuggestion of  Open source ExcelLibrary, I download it and I found a code example here :"https://stackoverflow.com/questions/151005/create-excel-xls-and-xlsx-file-from-c-sharp". But didn't fully understand how to proceed with these code lines ! Could anyone please explain to me more what shall i do to import data from the .xlsx file into labview using C !

Thank you for your help

0 Kudos
Message 19 of 22
(1,517 Views)

I know I pointed to the thread, but ExcelLibrary seems to be a bit old. Newer formats might not be supported.

0 Kudos
Message 20 of 22
(1,513 Views)