Home All Groups Group Topic Archive Search About
Author
7 Mar 2006 12:01 PM
philip
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

Author
7 Mar 2006 1:30 PM
Charles Law
Hi Philip

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

HTH

Charles


Show quoteHide quote
"philip" <p***@philippe.com> wrote in message
news:440d762b$0$6648$8fcfb975@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
>
Author
7 Mar 2006 2:47 PM
philip
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:
%23TJqLteQGHA.5***@TK2MSFTNGP10.phx.gbl...
Show quoteHide quote
> Hi Philip
>
> You can handle the BeforeNavigate2() event and do your own thing.
>
> HTH
>
> Charles
>
>
> "philip" <p***@philippe.com> wrote in message
> news:440d762b$0$6648$8fcfb975@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
>>
>
>
Author
7 Mar 2006 3:11 PM
Colin Neller
Philip,

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

Show quoteHide quote
"philip" <p***@philippe.com> wrote in message
news:440d9d06$0$20154$8fcfb975@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:
> %23TJqLteQGHA.5***@TK2MSFTNGP10.phx.gbl...
>> Hi Philip
>>
>> You can handle the BeforeNavigate2() event and do your own thing.
>>
>> HTH
>>
>> Charles
>>
>>
>> "philip" <p***@philippe.com> wrote in message
>> news:440d762b$0$6648$8fcfb975@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
>>>
>>
>>
>
>
Author
7 Mar 2006 3:20 PM
philip
But now, how can I know which HyperLink has been clicked ?

Thanks for help, Colin.

Philip

"Colin Neller" <cnel***@gmail.com> a écrit dans le message de news:
u6K%23njfQGHA.2***@TK2MSFTNGP11.phx.gbl...
Show quoteHide quote
> Philip,
>
> Using the 2005 WB, this event is called "navigating."
>
> --
> Colin Neller
> http://www.colinneller.com/blog
>
> "philip" <p***@philippe.com> wrote in message
> news:440d9d06$0$20154$8fcfb975@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:
>> %23TJqLteQGHA.5***@TK2MSFTNGP10.phx.gbl...
>>> Hi Philip
>>>
>>> You can handle the BeforeNavigate2() event and do your own thing.
>>>
>>> HTH
>>>
>>> Charles
>>>
>>>
>>> "philip" <p***@philippe.com> wrote in message
>>> news:440d762b$0$6648$8fcfb975@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
>>>>
>>>
>>>
>>
>>
>
>
Author
7 Mar 2006 5:48 PM
philip
Ok, I found.
I use e.Url
Thanks for you help

Philip

"Colin Neller" <cnel***@gmail.com> a écrit dans le message de news:
u6K%23njfQGHA.2***@TK2MSFTNGP11.phx.gbl...
Show quoteHide quote
> Philip,
>
> Using the 2005 WB, this event is called "navigating."
>
> --
> Colin Neller
> http://www.colinneller.com/blog
>
> "philip" <p***@philippe.com> wrote in message
> news:440d9d06$0$20154$8fcfb975@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:
>> %23TJqLteQGHA.5***@TK2MSFTNGP10.phx.gbl...
>>> Hi Philip
>>>
>>> You can handle the BeforeNavigate2() event and do your own thing.
>>>
>>> HTH
>>>
>>> Charles
>>>
>>>
>>> "philip" <p***@philippe.com> wrote in message
>>> news:440d762b$0$6648$8fcfb975@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
>>>>
>>>
>>>
>>
>>
>
>
Author
7 Mar 2006 2:58 PM
philip
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:
%23TJqLteQGHA.5***@TK2MSFTNGP10.phx.gbl...
Show quoteHide quote
> Hi Philip
>
> You can handle the BeforeNavigate2() event and do your own thing.
>
> HTH
>
> Charles
>
>
> "philip" <p***@philippe.com> wrote in message
> news:440d762b$0$6648$8fcfb975@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
>>
>
>
Author
7 Mar 2006 3:18 PM
philip
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:
%23TJqLteQGHA.5***@TK2MSFTNGP10.phx.gbl...
Show quoteHide quote
> Hi Philip
>
> You can handle the BeforeNavigate2() event and do your own thing.
>
> HTH
>
> Charles
>
>
> "philip" <p***@philippe.com> wrote in message
> news:440d762b$0$6648$8fcfb975@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
>>
>
>
Author
7 Mar 2006 3:28 PM
Colin Neller
> 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.
Author
7 Mar 2006 6:06 PM
philip
I found  e.Url in the event Navigating.
I can know which hyperlink was clicked.
Thank you for your help, sincerely.

Philip

"Colin Neller" <cnel***@gmail.com> a écrit dans le message de news:
uadmEtfQGHA.1***@TK2MSFTNGP12.phx.gbl...
Show quoteHide quote
>> 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
>