1. Sufyan Maghur
  2. PowerBuilder
  3. Thursday, 24 November 2022 13:46 PM UTC

Trying to replace inet with httpclient

 

What is the equivalent to

GetURL()     ---   Is it SEndRequest('GET',...)

HyperlinkToURL

 

Thank You

Chris Pollach @Appeon Accepted Answer Pending Moderation
  1. Thursday, 24 November 2022 15:48 PM UTC
  2. PowerBuilder
  3. # 1

Hi Sufyan;

  Note that the plan is to add the "HyperlinkToURL" method (or equivalent) to the HTTPClient in PB 2022 R2.

Regards ... Chris 

Comment
There are no comments made yet.
Andreas Mykonios Accepted Answer Pending Moderation
  1. Thursday, 24 November 2022 14:02 PM UTC
  2. PowerBuilder
  3. # 2

Hi. As David answered, yes.

You can always test it. The following will return the html for the page.

integer li_err
string ls_response_body
httpclient lnv_httpclient

lnv_httpclient = create httpclient
li_err = lnv_httpclient.SendRequest("GET", "https://www.google.gr")
messagebox("", lnv_httpclient.getresponsebody(ls_response_body, EncodingUTF8!))
messagebox("", ls_response_body)
if isvalid(lnv_httpclient) then destroy lnv_httpclient
Comment
There are no comments made yet.
David Peace (Powersoft) Accepted Answer Pending Moderation
  1. Thursday, 24 November 2022 13:57 PM UTC
  2. PowerBuilder
  3. # 3

Hi

Yes you would use the SendRequest to send the GEt Request and then use GetResponseBody to retrieve the returned values.

There are examples in the Help.

Comment
There are no comments made yet.
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.
We use cookies which are necessary for the proper functioning of our websites. We also use cookies to analyze our traffic, improve your experience and provide social media features. If you continue to use this site, you consent to our use of cookies.