user2618133
user2618133

Reputation: 1

webbrowser c++ buider how to prevent executing "mailto" when a link of this type is clicked

I use c++buider4 and TWebBrowser. How can I avoid "mailto" to be executed when this type of link is clicked? Actually, I dont want this link to be executed because when it's executed, it switch to mail application and open a new windows. Thanks

Upvotes: 0

Views: 142

Answers (1)

Remy Lebeau
Remy Lebeau

Reputation: 597885

Use the OnBeforeNavigate2 event to cancel the operation if the URL being requested starts with mailto:.

Upvotes: 2

Related Questions