hBrowse Example
Keywords: hBrowse
Question:
In your definition of the HBROWSE function you have the following example:
AddExtender("WWHTM34I.DLL")
url = "http://www.windowware.com"
WinTitle("",url)
url = hBrowse(2,url,1)
**while url!=""
** WinTitle("",url)
** url=hBrowse(1,"",1)
**endwhile
hBrowse(0,"",1)
exit
I don't understand what the section that I marked with ** is doing. Could you explain?
Answer:
;Add the HTML Dialog extender
AddExtender("WWHTM34I.DLL")
;Set up the initial URL for the first hBrowse function call
url = "http://www.windowware.com"
;Set the Window title to the URL for lack of anything better
WinTitle("",url)
;Tell the extender to display the url in a html dialog window
url = hBrowse(2,url,1)
;Note that if the user clicks on *any* link, the clicked on
;field is returned via the URL variable. If they click "CLOSE"
;then the URL variable is set to a null string ""
;So... while the url variable is NOT null,
;continue this while loop
while url!=""
;Set the title to the new url
WinTitle("",url)
;Allow "default" Browser processing to occur
;as in load the link the user clicked on
url=hBrowse(1,"",1)
endwhile
;Close HTML Dialog window
hBrowse(0,"",1)
exit
Article ID: W14182
Filename: hBrowse Example.txt