Hi,
I am using the following code to read data from a web service. However, i get the same Picture every time.
How do i clear the Blob to get the new picture?
I am using PB 2018 R3 Build 1858.
Thanks
http = create httpclient
li_rc = http.ClearRequestHeaders ( )
http.AutoReadData = false
http.setrequestheader('X-API_KEY',is_api_key)
http.setrequestheader('X-CompanyName',is_cust_no)
http.setrequestheader('X-UserName',is_user_id)
li_rc=0
li_rc = http.sendrequest( 'GET', ls_url)
IF li_rc = 1 and http.GetResponseStatusCode() = 200 THEN
DO WHILE True
li_rc = http.ReadData(lblb_NextData, 1024*16)
if li_rc = 0 then exit // Finish receiving data
if li_rc = -1 then exit // Error occurred
if li_rc = -2 then exit // Timed out
iblb_photo += lblb_NextData
LOOP
ELSE
MessageBox('Error','Unable to view th picture at this time.')
Return
END IF