|
| WB -> WM using HTTPRequest |
| Iniciado por guest, 18,abr. 2015 09:37 - 2 respuestas |
| |
| | | |
|
| |
| Publicado el 18,abril 2015 - 09:37 |
Hi all Using WX19
I have this code in a WB Procedure which ic called via HTTPRequest ------------------------ sResult is STRING UNICODE
sResult = "abc" STRINGDISPLAY(sResult) -----------------------
In a WM procedure I have sResult is STRING UNICODE
IF HTTPRequest("<a class="ExternalLink" rel="nofollow" target="_blank" href="http://somesite/somepage.awp">http://somesite/somepage.awp</a>) = True THEN sResult = HTTPGetResult() EDT_NoName1 = sResult ELSE EDT_NoName1 = "Oops!"
------------------------------
Works fine in the WM emulator, but on an actual device sResult is always empty. I know the HTTPRequest is successful, except no visible data comes back. I have tried sResult being ANSI, UNICODE, and Buffer (on both ends). Nothing seems to work.
Any suggestions appreciated.
Rgds Paul |
| |
| |
| | | |
|
| | |
| |
| Publicado el 18,abril 2015 - 10:58 |
To follow on, I downloaded Fabrice's replication project to see his method, and copied that. Still the same result - an empty string. What I tried was:
WB Project - set to ANSI under Configuration Sending Code. sSend is ANSI string sSend = "Here is my answer! + some extra" StringDisplay(sSend)
WM Project - set to UNICODE under Configuration Recieving Code sResult is ANSI string IF HTTPRequest("<a class="ExternalLink" rel="nofollow" target="_blank" href="http://web-pc/WAITING_TIMES_WEB/AU/PAGE_Webservices2.awp?P1=P">http://web-pc/WAITING_TIMES_WEB/AU/PAGE_Webservices2.awp…</a>") = True THEN sResult = HTTPGetResult(httpResult) sConverted = AnsiToUnicode(sResult) EDT_NoName1 = sConverted ELSE EDT_NoName1 = "Oops!"
This still receives an empty string. |
| |
| |
| | | |
|
| | |
| |
| Publicado el 18,abril 2015 - 14:20 |
| Pleased to say I have solved this. |
| |
| |
| | | |
|
| | | | |
| | |
|