I was wondering if I open a website in a web browser box, is there some JSL code that you can use to save a local HTML file of the website?
I don't about using the web browse box, but if you can load the HTML contents of a web page simply using the Open() function. This creates a text string variable which can be saved to a text (html) file:
url = "http://www.imdb.com/title/tt0120338/";
strHtml = Open(url);
Save Text File("local.html", strHtml);
Anything other than trivial HTML pages will contain a significant number of external file references (style sheets, images etc) so I think making a local copy has limited capability. However, you can use the technique to search for content ("screen-scraping"). In the example below the movie description is extracted from the IMDB website:
Thanks for the reply, Unfortunately this will not work in my case as I am actually trying to read in an SSRS report and extract a data table from it.
I can manually open the link with the following:
and then manually use the File<Import table as data table from the drop down to get the table I need, or can also open the report in a web browser and then save a local HTML file to my disk which I can read in with JMP no problem using open(url,HTML Table( n ))
this was why I was wondering if you could save from a web browser box. I am trying to automate the table extraction from the SSRS report.
I think I am running out of options and may have to resort to actually pressing a few buttons to import the data
Thanks for the reply, it will certainly be useful in the future!!
So I am guessing that the SSRS report uses some AJAX-enabled components that update the web page after the page has "loaded".
It doesn't look like the web browser box supports any messages to retrieve the HTML content.
Abit long-winded, but JMP is OLE-enabled; also it can load and utilise DLLs so you could maybe use some .NET code instead of the web browser box in order to access the report content (at this point button pressing starts to feel more attractive!)