Showing results for 
Search instead for 
Did you mean: 

Response to AJAX HTTP Request with LabVIEW

Go to solution

Dear reader, 


I'm trying to have Labview request data from an ajax call 


So, labview request data from a web service, the web service respond and I get the data in labVIEW ! As simple as that ! 


However, even using i'm having trouble using it...


on the getlogin.html, I changed the url to have the request of what I want ; When open the file, I click on "get login", boom, I have in the console the data I want ! WIN ! 

So, now I would like to have that response in LabVIEW ! 

FYI, the answer from the ajax request is JSON, so I should be able to "explode" it in LabVIEW no problem (As long as I got it there !)


In labview, the error I got is -67301 : 

Possible reason(s):

LabVIEW: (Hex 0xFFFEF91B) LabVIEW Web Services: Invalid Request ID.

Complete call chain:
NI_WebServices.lvlib:Error Converter (ErrCode or Status).vi
NI_WebServices.lvlib:Web Request.lvclass:Set HTTP Response MIME


Probably something stupid, but any help is appreciated ! 


Thank you ! 



0 Kudos
Message 1 of 8

If you attached a VI, it would help show us what you are doing.


Without it, we can only guess.  My first thought is that you need something in the header of the HTTP request.

0 Kudos
Message 2 of 8

I literraly use the one from the example here : ; Except the url ; I changed it to something internal to our network

Except for that, exactly the same ! 



0 Kudos
Message 3 of 8

Howdy ! 


Here is the code I'm trying to execute ; 

It does a simple ajax call to  a test server and get a data ; 

The HTML works and populate the box ; I would like to have the value of that box in labview ! 


Do you think this is possible ? 


Thank you for all your help ! 



0 Kudos
Message 4 of 8

Please attach a true zip file and not a .7z file.


No reason to make others install 3rd part programs when Windows natively handles zip files

0 Kudos
Message 5 of 8

My bad...


see attached

0 Kudos
Message 6 of 8
Accepted by BenDur

following this solution, I solved my problem !


Thank you



0 Kudos
Message 7 of 8


0 Kudos
Message 8 of 8