LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Fill a Google form with http POST VI

Solved!
Go to solution

Dear LabVIEW forum,

 

I am trying to fill a very simple Google form consisting in 4 text fields named AI0, AI1, AI2 and AI3.

 

I use the http POST VI provided by LabVIEW:

 

BD.png

 

When I execute this, a new line is added to the response spreadsheet, but the values don't appear, except for the timestamp.

 

What am I doing wrong?

 

Thanks!

LabVIEW 2013 SP1
Windows 7 64bit
Windows Server 2012 64 bit
Windows 8.1 32 bit
0 Kudos
Message 1 of 5
(4,811 Views)
That seems strange - your query string etc. looks fine.

I would try testing outside of LabVIEW - I'd set up a html page with a form and 4 input fields with the names AI0, AI1, AI2, AI3 and a submit button to submit to the URL you posted.

If that works - then it's something to do with LabVIEW sending the data. If it doesn't, if you have access to a web server - you could try creating a simple PHP script that saves the POST data to a file.

Also - have you checked the body/headers that are returned from the VI, maybe there are some clues in there!

LabVIEW Champion, CLA, CLED, CTD
(blog)
0 Kudos
Message 2 of 5
(4,791 Views)
Solution
Accepted by Baobob

Hi

I had a quick look at the form and the text next to the input boxes is AI0 ... but the names of the input text boxes are not AI0 etc. You may have to get the page first and then parse the page for the name of the entry.

<input type="text" name="entry.2117155241" value="" class="ss-q-short" id="entry_2117155241" dir="auto" title="">

 

Mike

Message 3 of 5
(4,781 Views)

Hey Sam and Mike, thank you both for your ideas.

 

Mike, I indeed could succesfully submit the form usin e.g. entry.890857272=12 instead of AI0=12.

LabVIEW 2013 SP1
Windows 7 64bit
Windows Server 2012 64 bit
Windows 8.1 32 bit
0 Kudos
Message 4 of 5
(4,776 Views)

I have been using this method successfully for a few months, but it just stopped working last week. All of the names of the form fields appear to be the same, (entry.12345 etc) but it no longer posts to the Google Spreadsheet. Any one else experience this? I'm assuming it is some change on Google's end.

 

EDIT: Turns out the Labview POST is still working fine, but new entries were just being inserted at random places in the spreadsheet form. After sorting it seems to be fixed for now ... fingers crossed.

Message 5 of 5
(4,640 Views)