PC Review


Reply
Thread Tools Rate Thread

calling event function

 
 
Gunawan
Guest
Posts: n/a
 
      24th Aug 2006
I have define event handler call btnFind_Click
protected void btnFind_Click(object sender, EventArgs e)

{

....

}


What I want to do is calling this function from another function.
what should I do with the parameters coz I can't call this function using

btnFind_Click();

TIA
Gun


 
Reply With Quote
 
 
 
 
Mark Fitzpatrick
Guest
Posts: n/a
 
      24th Aug 2006
Instead of trying to call this function directly, have your btnFind_Click
event handler call another function. That way you can reference it from
anywhere in your page's code.

Hope this helps,
Mark Fitzpatrick
Microsoft MVP - FrontPage


"Gunawan" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
>I have define event handler call btnFind_Click
> protected void btnFind_Click(object sender, EventArgs e)
>
> {
>
> ...
>
> }
>
>
> What I want to do is calling this function from another function.
> what should I do with the parameters coz I can't call this function using
>
> btnFind_Click();
>
> TIA
> Gun
>
>



 
Reply With Quote
 
Gunawan
Guest
Posts: n/a
 
      24th Aug 2006
Thanks Mark,
That is a workaround that never cross my mind.
Regards,
Gun

"Mark Fitzpatrick" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Instead of trying to call this function directly, have your btnFind_Click
> event handler call another function. That way you can reference it from
> anywhere in your page's code.
>
> Hope this helps,
> Mark Fitzpatrick
> Microsoft MVP - FrontPage
>
>
> "Gunawan" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
>>I have define event handler call btnFind_Click
>> protected void btnFind_Click(object sender, EventArgs e)
>>
>> {
>>
>> ...
>>
>> }
>>
>>
>> What I want to do is calling this function from another function.
>> what should I do with the parameters coz I can't call this function using
>>
>> btnFind_Click();
>>
>> TIA
>> Gun
>>
>>

>
>



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
calling a function without a page load event? darrel Microsoft Dot NET Framework 5 7th Dec 2005 02:33 PM
Re: Calling event from initialise function Konrad L. M. Rudolph Microsoft C# .NET 0 13th May 2004 08:29 PM
'System.MissingMethodException' when calling function from Mousedown Event?? PocketDeveloper Microsoft Dot NET Compact Framework 3 2nd Apr 2004 10:47 PM
Calling DHTML function from code behind event handler Lachlan Gemmell Microsoft ASP .NET 3 23rd Jan 2004 10:26 AM
Calling a javascript function on asp:button's click event Praveen Ladwani Microsoft VB .NET 1 13th Jan 2004 08:04 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 09:15 PM.