Develop Your Own Browser - Part 1
Insert these coding into your Click Event:
Dim eQuery As OLECMDF return value type for QueryStatusWBOn Error Resume NexteQuery = webbrowser1.QueryStatusWB(OLECMDID_PROPERTIES)If Err.Number = 0 ThenIf eQuery And OLECMDF_ENABLED ThenWebbrowser1.ExecWB OLECMDID_PROPERTIES, _ OLECMDEXECOPT_PROMPTUSER, , _ Ok to Print?ElseMsgBox No contents in WebbrowserEnd IfEnd If
Page 6 of 7
This article was originally published on November 20, 2002