I've searched but unable to find what I am looking for.
I want to change the default context menu with my own. That will only have a print option, I don't need any of the others.
How do I go about doing that?
Also, how do I change the header/footer?
Printable View
I've searched but unable to find what I am looking for.
I want to change the default context menu with my own. That will only have a print option, I don't need any of the others.
How do I go about doing that?
Also, how do I change the header/footer?
Wow, I thought I put that in, I am sorry.
It's a Webbrowser control.
I've managed to disable it, but I would rather replace it to give the user the option to print, but only if I can figure out how to change the header/footer. Reason of rthat, is because when it prints, it says it's printing the URL "about:blank" since I am changing the text it doesn't change that.
Add a context menu to the form, create menu item(s), then assign the context menu to the webbrowser.
Dismiss the WebBrowser's default context menu
Code:WebBrowser1.IsWebBrowserContextMenuEnabled = False
Code:Private Sub Form2_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) _
Handles MyBase.Load
WebBrowser1.AllowNavigation = True
WebBrowser1.Navigate("http://www.google.com")
WebBrowser1.IsWebBrowserContextMenuEnabled = False
End Sub
Private Sub PrintToolStripMenuItem_Click(ByVal sender As System.Object, _
ByVal e As System.EventArgs) _
Handles PrintToolStripMenuItem.Click
MsgBox("Your print code goes here")
End Sub