‎2012 May 07 1:32 PM
Dear expert, I'm founding problem to display a html page wirh HTML_VIEWER.
The page content is ok (all the image and text are displaied) but a javacript error occurs.
If I click to "OK" to the message the page is shown correctly.
My question is: is there the way to suppress script error message using HTML_VIEWER?
I'm using the following methods and for me are ok:
CALL METHOD html_control->load_data
IMPORTING
assigned_url = doc_url
CHANGING
data_table = i_tab[]
EXCEPTIONS
dp_invalid_parameter = 1
dp_error_general = 2
cntl_error = 3
OTHERS = 4.
IF sy-subrc EQ 0.
CALL METHOD html_control->show_url
EXPORTING
url = doc_url.
* IN_PLACE = ' '.
Thank you in advance,
Davide
‎2012 May 07 6:29 PM
Is it a specific error? It may be that IE is prompting to run the javascript, which is by design. Check out the bottom of this thread for more information.
‎2012 May 07 7:03 PM
Hi, It's a specific error. I'm not using IE but HTML VIEWER in a ABAP modue pool.
The error is not relevant for my html, in fact it works correctly. I don't know the reason of it but, anyway,i'm only interested to suppress it. Is it possible ?
Regards,
Davide
‎2012 May 07 8:18 PM
What is error? Can we see the screen shot? Do you get the same error while running the demo program SAPHTML_DEMO1.
HTML uses IE to render the page and display.
Regards,
Naimesh Patel
‎2012 May 07 8:29 PM
Chances are it is Internet Explorer. Using the HTML_VIEWER and browse to http://detectmybrowser.com/ . In any case, the javascript error will need to be handled to avoid the behavior you're seeing.
‎2012 May 08 10:41 AM
Hi, i cannot run the program SAPHTML_DEMO1 because I'm not using a URL WWW... but I'm using HTML VIEWER to upload an external HTML FILE.
The error that I have is
Script error:an error has occurred in the script on this page
Error: Access is denied
Here I cannot attach html file becuase the format is not supported, but in case I can send you the file by mail to check it.
The strange thing that I don't understant is that I have the following error using IE, but if I open the html using a notepad and save it again, then It works.
How is it possible ?
Regards,
Davide
‎2012 May 08 11:34 AM
Can you download the content of i_tab[] as text file from the debbuger tool and upload that text file?
It will be easier to find the issue.