1. Mickey Hillel
  2. PowerBuilder
  3. Monday, 21 June 2021 09:09 AM UTC

Hi all,

I'm on PB2019 R3 2703, and using the new webbrowser control.

Some events are missing from this control

  • clicked
  • losefocus

Also, the Navigate function does not return an error if the url is incorrect. Always returns 1.

Any ideas?

TIA,

Mickey Hillel

Mickey Hillel Accepted Answer Pending Moderation
  1. Wednesday, 23 June 2021 06:13 AM UTC
  2. PowerBuilder
  3. # 1

Thank you for your replies.

Clicked event should definitely be part of the controls' event. Hope it will be fixed in coming version.

Since there is a GetFocus, there should also be a LoseFocus event (this does not seem to be a documentation error).

As for Navigate return code, maybe this is a documentation error,  but ZhaoKai replied that 404 is not a URL failure.

I used  the following to get the 404 error (maybe this should be added to the documentation)

>>>>

lo_httpclient = Create HttpClient

li_rc = lo_httpclient.SendRequest('HEAD', ls_url)

if li_rc = 1 then
li_response = lo_httpclient.GetResponseStatusCode()

choose case li_response
case 200
// ok
case 404
return
case else
return
end choose
end if

destroy lo_httpclient

>>>

 

Regards,

Mickey

Comment
  1. Kai Zhao @Appeon
  2. Wednesday, 23 June 2021 23:57 PM UTC
Hi Mickey,



Thanks for your valuable suggestion. I'll record it as a new requirement/enhancement request and transfer it to our product team for consideration.



Regards,

ZhaoKai
  1. Helpful
There are no comments made yet.
Kai Zhao @Appeon Accepted Answer Pending Moderation
  1. Tuesday, 22 June 2021 02:58 AM UTC
  2. PowerBuilder
  3. # 2

Hi Mickey,

For the event issue, sorry that neither clicked nor losefocus is supported by webbrowser control so they are not listed from this control. We notice losefocus is listed as support in the document, we will inform the document team to correct this.

For the Navigate issue, generally, it will trigger the navigateerror event, such as the URL below that specifies the non-existing host name.
Http://demo1234

Please note the HTTP error like 404 will not trigger navigateerror event. Web server redirects to the error page, in this case, Navigate function gets the normal response from the web server and will return 1.

Regards,
ZhaoKai

Comment
There are no comments made yet.
Chris Pollach @Appeon Accepted Answer Pending Moderation
  1. Monday, 21 June 2021 18:45 PM UTC
  2. PowerBuilder
  3. # 3

Hi Mickey;

  Please open a Support Ticket for these issues. Some are known (ie: no Clicked Event support) but others you mention should also be added to the enhancement list. The Navigate() positive return code could be a issue. Have you checked the NavigationError event when the URL fails?

Regards ... Chris

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.