PC Review


Reply
Thread Tools Rate Thread

Creating an event by force.

 
 
Mr. X.
Guest
Posts: n/a
 
      10th Jun 2010
Hello,
I want to create an event by force.
How can I do that ?

(for example : ToolStrip.ItemClicked event)

Thanks
 
Reply With Quote
 
 
 
 
Martin H.
Guest
Posts: n/a
 
      10th Jun 2010
To the dark side this path leads.
Explain your request you should.

Yoda
 
Reply With Quote
 
Family Tree Mike
Guest
Posts: n/a
 
      10th Jun 2010
On 6/10/2010 6:06 PM, Mr. X. wrote:
> Hello,
> I want to create an event by force.
> How can I do that ?
>
> (for example : ToolStrip.ItemClicked event)
>
> Thanks


Do you mean SomeToolstrip.Items (0).PerformClick()?

--
Mike
 
Reply With Quote
 
Mr. X.
Guest
Posts: n/a
 
      11th Jun 2010
Thanks,
specific, this help.
I need more generic solution (I would like to do any event, not only the
PerformClick event).

Thanks

"Family Tree Mike" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> On 6/10/2010 6:06 PM, Mr. X. wrote:
>> Hello,
>> I want to create an event by force.
>> How can I do that ?
>>
>> (for example : ToolStrip.ItemClicked event)
>>
>> Thanks

>
> Do you mean SomeToolstrip.Items (0).PerformClick()?
>
> --
> Mike


 
Reply With Quote
 
Phill W.
Guest
Posts: n/a
 
      11th Jun 2010
On 11/06/2010 10:53, Mr. X. wrote:

> I need more generic solution (I would like to do any event, not only the
> PerformClick event).


If a class doesn't provide you with a method to do something, then
perhaps it's something that you shouldn't do?

Why do you want to fire off any event from any control?

Regards,
Phill W.
 
Reply With Quote
 
Armin Zingler
Guest
Posts: n/a
 
      11th Jun 2010
Am 11.06.2010 00:06, schrieb Mr. X.:
> Hello,
> I want to create an event by force.
> How can I do that ?
>
> (for example : ToolStrip.ItemClicked event)
>
> Thanks


You are taking the wrong approach. If you want
to do something, call a method. If you want
the same thing to be done if the item is clicked,
call the same method from the click event handler.

--
Armin
 
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
Force An OnClick Event =?Utf-8?B?Uml0YUc=?= Microsoft ASP .NET 2 9th Mar 2007 10:28 PM
Force Worksheet_Change event glen.e.mettler@lmco.com Microsoft Excel Programming 1 10th Apr 2006 08:28 PM
Force button event? Adam Honek Microsoft VB .NET 14 29th Apr 2005 11:17 PM
Re: Force an event? Albert D. Kallal Microsoft Access VBA Modules 0 16th Aug 2003 10:58 PM
Re: Force an event? Tim Ferguson Microsoft Access VBA Modules 1 16th Aug 2003 08:20 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 08:44 PM.