Microsoft Web Browser OLE control and JavaScript errors
Symptom
When using the Microsoft Web Browser OLE control in a PowerBuilder
application some webpages show JavaScript errors, is there a way to
eliminate these?
Environment
-
PowerBuilder
-
PowerBuilder application with a Microsoft Web Browser OLE
control
Cause
The Microsoft Web Browser OLE control is a third party control and
the errors can be replicated with other tools. Please refer to the
Microsoft site for further information on this control.
Solution
To suppress the JavaScript errors in your
PowerBuilder application, use ole_1.object.silent=1 before
navigate(). Code snippet below:
|
1 2 |
ole_1.object.silent=1 ole_1.object.navigate("www.appeon.com") |
This will not eliminate the root cause of the JavaScript
errors, the additional line of code just suppresses the errors.