473,385 Members | 2,069 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

WebBrowser

Is it possible, on a WebBrowser control, to intercept a HyperLink and react
programmatically to this click ?
That's my first question.

In fact, I use the Webbrowser as a sort of report (I write the html code and
tables programmatically in a string, and I give the string to the property
DocumentText of the WebBrowser, and I insert in this code some Hyperlinks by
wich I could react, launching an specific action)
The properties ShowPrintPreviewDialog and others 'Show...' properties of the
WebControl are very interresting, and sometimes better then using true
Reports or CrystalReports

The second question is : is there a document somewhere who discuss on this
subject, comparing CrystalReports and use of WebBrowser in their function of
showing reports ? I try to explore this way.

Thanks for your response
Mar 7 '06 #1
9 3131
Hi Philip

You can handle the BeforeNavigate2() event and do your own thing.

HTH

Charles
"philip" <ph**@philippe.com> wrote in message
news:44**********************@news.wanadoo.fr...
Is it possible, on a WebBrowser control, to intercept a HyperLink and
react programmatically to this click ?
That's my first question.

In fact, I use the Webbrowser as a sort of report (I write the html code
and tables programmatically in a string, and I give the string to the
property DocumentText of the WebBrowser, and I insert in this code some
Hyperlinks by wich I could react, launching an specific action)
The properties ShowPrintPreviewDialog and others 'Show...' properties of
the WebControl are very interresting, and sometimes better then using true
Reports or CrystalReports

The second question is : is there a document somewhere who discuss on this
subject, comparing CrystalReports and use of WebBrowser in their function
of showing reports ? I try to explore this way.

Thanks for your response

Mar 7 '06 #2
I don't discover this event in WebBrowser.
I have Visual Studio 2005.
Is it normal ?
Must I have a reference ?

Thanks for your help

Philip

"Charles Law" <bl***@nowhere.com> a écrit dans le message de news:
%2****************@TK2MSFTNGP10.phx.gbl...
Hi Philip

You can handle the BeforeNavigate2() event and do your own thing.

HTH

Charles
"philip" <ph**@philippe.com> wrote in message
news:44**********************@news.wanadoo.fr...
Is it possible, on a WebBrowser control, to intercept a HyperLink and
react programmatically to this click ?
That's my first question.

In fact, I use the Webbrowser as a sort of report (I write the html code
and tables programmatically in a string, and I give the string to the
property DocumentText of the WebBrowser, and I insert in this code some
Hyperlinks by wich I could react, launching an specific action)
The properties ShowPrintPreviewDialog and others 'Show...' properties of
the WebControl are very interresting, and sometimes better then using
true Reports or CrystalReports

The second question is : is there a document somewhere who discuss on
this subject, comparing CrystalReports and use of WebBrowser in their
function of showing reports ? I try to explore this way.

Thanks for your response


Mar 7 '06 #3
I don't discover this event in WebBrowser.
I have Visual Studio 2005.
Is it normal ?
Must I ADD a reference ?

Thanks for your help

Philip

"Charles Law" <bl***@nowhere.com> a écrit dans le message de news:
%2****************@TK2MSFTNGP10.phx.gbl...
Hi Philip

You can handle the BeforeNavigate2() event and do your own thing.

HTH

Charles
"philip" <ph**@philippe.com> wrote in message
news:44**********************@news.wanadoo.fr...
Is it possible, on a WebBrowser control, to intercept a HyperLink and
react programmatically to this click ?
That's my first question.

In fact, I use the Webbrowser as a sort of report (I write the html code
and tables programmatically in a string, and I give the string to the
property DocumentText of the WebBrowser, and I insert in this code some
Hyperlinks by wich I could react, launching an specific action)
The properties ShowPrintPreviewDialog and others 'Show...' properties of
the WebControl are very interresting, and sometimes better then using
true Reports or CrystalReports

The second question is : is there a document somewhere who discuss on
this subject, comparing CrystalReports and use of WebBrowser in their
function of showing reports ? I try to explore this way.

Thanks for your response


Mar 7 '06 #4
Philip,

Using the 2005 WB, this event is called "navigating."

--
Colin Neller
http://www.colinneller.com/blog

"philip" <ph**@philippe.com> wrote in message
news:44***********************@news.wanadoo.fr...
I don't discover this event in WebBrowser.
I have Visual Studio 2005.
Is it normal ?
Must I have a reference ?

Thanks for your help

Philip

"Charles Law" <bl***@nowhere.com> a écrit dans le message de news:
%2****************@TK2MSFTNGP10.phx.gbl...
Hi Philip

You can handle the BeforeNavigate2() event and do your own thing.

HTH

Charles
"philip" <ph**@philippe.com> wrote in message
news:44**********************@news.wanadoo.fr...
Is it possible, on a WebBrowser control, to intercept a HyperLink and
react programmatically to this click ?
That's my first question.

In fact, I use the Webbrowser as a sort of report (I write the html code
and tables programmatically in a string, and I give the string to the
property DocumentText of the WebBrowser, and I insert in this code some
Hyperlinks by wich I could react, launching an specific action)
The properties ShowPrintPreviewDialog and others 'Show...' properties of
the WebControl are very interresting, and sometimes better then using
true Reports or CrystalReports

The second question is : is there a document somewhere who discuss on
this subject, comparing CrystalReports and use of WebBrowser in their
function of showing reports ? I try to explore this way.

Thanks for your response



Mar 7 '06 #5
Perhaps the event 'Navigating' replace the 'BeforeNavigate2' event ?
I can use e.Cancel to cancel and do my own thing.

But now, how can I know which HyperLink has been clicked ?

Thanks for help, Charles.

Philip

"Charles Law" <bl***@nowhere.com> a écrit dans le message de news:
%2****************@TK2MSFTNGP10.phx.gbl...
Hi Philip

You can handle the BeforeNavigate2() event and do your own thing.

HTH

Charles
"philip" <ph**@philippe.com> wrote in message
news:44**********************@news.wanadoo.fr...
Is it possible, on a WebBrowser control, to intercept a HyperLink and
react programmatically to this click ?
That's my first question.

In fact, I use the Webbrowser as a sort of report (I write the html code
and tables programmatically in a string, and I give the string to the
property DocumentText of the WebBrowser, and I insert in this code some
Hyperlinks by wich I could react, launching an specific action)
The properties ShowPrintPreviewDialog and others 'Show...' properties of
the WebControl are very interresting, and sometimes better then using
true Reports or CrystalReports

The second question is : is there a document somewhere who discuss on
this subject, comparing CrystalReports and use of WebBrowser in their
function of showing reports ? I try to explore this way.

Thanks for your response


Mar 7 '06 #6
But now, how can I know which HyperLink has been clicked ?

Thanks for help, Colin.

Philip

"Colin Neller" <cn*****@gmail.com> a écrit dans le message de news:
u6****************@TK2MSFTNGP11.phx.gbl...
Philip,

Using the 2005 WB, this event is called "navigating."

--
Colin Neller
http://www.colinneller.com/blog

"philip" <ph**@philippe.com> wrote in message
news:44***********************@news.wanadoo.fr...
I don't discover this event in WebBrowser.
I have Visual Studio 2005.
Is it normal ?
Must I have a reference ?

Thanks for your help

Philip

"Charles Law" <bl***@nowhere.com> a écrit dans le message de news:
%2****************@TK2MSFTNGP10.phx.gbl...
Hi Philip

You can handle the BeforeNavigate2() event and do your own thing.

HTH

Charles
"philip" <ph**@philippe.com> wrote in message
news:44**********************@news.wanadoo.fr...
Is it possible, on a WebBrowser control, to intercept a HyperLink and
react programmatically to this click ?
That's my first question.

In fact, I use the Webbrowser as a sort of report (I write the html
code and tables programmatically in a string, and I give the string to
the property DocumentText of the WebBrowser, and I insert in this code
some Hyperlinks by wich I could react, launching an specific action)
The properties ShowPrintPreviewDialog and others 'Show...' properties
of the WebControl are very interresting, and sometimes better then
using true Reports or CrystalReports

The second question is : is there a document somewhere who discuss on
this subject, comparing CrystalReports and use of WebBrowser in their
function of showing reports ? I try to explore this way.

Thanks for your response



Mar 7 '06 #7
> Perhaps the event 'Navigating' replace the 'BeforeNavigate2' event ?
I can use e.Cancel to cancel and do my own thing. That is correct. The 2005 WB changes the event name to "Navigating"
But now, how can I know which HyperLink has been clicked ?

It would help to know exactly what you're trying to do. If you need to know
the specific anchor tag that was clicked, then you'll actually need to sink
the events from the HTMLDocument its self and capture the "onclick" event
rather than the "Navigating" event.
--
Colin Neller
http://www.colinneller.com/blog
Mar 7 '06 #8
Ok, I found.
I use e.Url
Thanks for you help

Philip

"Colin Neller" <cn*****@gmail.com> a écrit dans le message de news:
u6****************@TK2MSFTNGP11.phx.gbl...
Philip,

Using the 2005 WB, this event is called "navigating."

--
Colin Neller
http://www.colinneller.com/blog

"philip" <ph**@philippe.com> wrote in message
news:44***********************@news.wanadoo.fr...
I don't discover this event in WebBrowser.
I have Visual Studio 2005.
Is it normal ?
Must I have a reference ?

Thanks for your help

Philip

"Charles Law" <bl***@nowhere.com> a écrit dans le message de news:
%2****************@TK2MSFTNGP10.phx.gbl...
Hi Philip

You can handle the BeforeNavigate2() event and do your own thing.

HTH

Charles
"philip" <ph**@philippe.com> wrote in message
news:44**********************@news.wanadoo.fr...
Is it possible, on a WebBrowser control, to intercept a HyperLink and
react programmatically to this click ?
That's my first question.

In fact, I use the Webbrowser as a sort of report (I write the html
code and tables programmatically in a string, and I give the string to
the property DocumentText of the WebBrowser, and I insert in this code
some Hyperlinks by wich I could react, launching an specific action)
The properties ShowPrintPreviewDialog and others 'Show...' properties
of the WebControl are very interresting, and sometimes better then
using true Reports or CrystalReports

The second question is : is there a document somewhere who discuss on
this subject, comparing CrystalReports and use of WebBrowser in their
function of showing reports ? I try to explore this way.

Thanks for your response



Mar 7 '06 #9
I found e.Url in the event Navigating.
I can know which hyperlink was clicked.
Thank you for your help, sincerely.

Philip

"Colin Neller" <cn*****@gmail.com> a écrit dans le message de news:
ua**************@TK2MSFTNGP12.phx.gbl...
Perhaps the event 'Navigating' replace the 'BeforeNavigate2' event ?
I can use e.Cancel to cancel and do my own thing.

That is correct. The 2005 WB changes the event name to "Navigating"
But now, how can I know which HyperLink has been clicked ?

It would help to know exactly what you're trying to do. If you need to
know the specific anchor tag that was clicked, then you'll actually need
to sink the events from the HTMLDocument its self and capture the
"onclick" event rather than the "Navigating" event.
--
Colin Neller
http://www.colinneller.com/blog

Mar 7 '06 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Jim Hubbard | last post by:
How would I implement the IDispatch interface to handle the following in VB.Net <BEGIN> Controlling Download and Execution The WebBrowser Control gives you control over what it downloads,...
5
by: SPE - Stani's Python Editor | last post by:
Hi, During optimizing SPE for Ubuntu, I found something strange. I have Ubuntu 5.10 "The Breezy Badger" and unfortunately this code is not working: >>> import webbrowser >>>...
12
by: Alex Clark | last post by:
Greetings, (.NET 2.0, WinXP Pro/Server 2003, IE6 with latest service packs). I've decided to take advantage of the layout characteristics of HTML documents to simplify my printing tasks, but...
8
by: Prosperz | last post by:
Hi, I would like to make thumbnails of web page by capture content of a WebBrowser. By example, capture http://www.google.com. I used WebBrowser control with Framework 2.0. I try this : ...
8
by: Dustan | last post by:
At http://docs.python.org/whatsnew/modules.html on the webbrowser module, it says "A number of additional browsers were added to the supported list such as Firefox, Opera, Konqueror, and elinks." ...
11
by: Anil Gupte | last post by:
....and how do I insert one into my form? I used in VB 6.0 last, but cannot figure out where it is in .Net Thanx, -- Anil Gupte www.keeninc.net www.icinema.com
18
by: Zytan | last post by:
I have multiple threads writing to WebBrowser (using a function that checks InvokedRequired, and if so, invokes itself on the WebBrowser thread) and they are getting deadlocked. They only...
4
by: Gregory Bloom | last post by:
I'm running Python 2.5 under Windows. If I fire up IDLE and enter: it works like a champ, opening the page in Firefox. Same thing goes from a Windows cmd shell: it works as advertised. But...
11
by: kimiraikkonen | last post by:
Hi there, I needed to use MouseOver event on Webbrowser which is NOT provided by webbrowser control natively(what a disappointment), so i decided to go with another route to simulate this like: ...
3
by: TedTrippin | last post by:
Hi, Background - I've create a windows application in VS and added a WebBrowser component and all works well. I'm now trying to do this programmatically. My application now listens on a socket...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.