Click here to Skip to main content
15,894,405 members
Home / Discussions / C#
   

C#

 
AnswerRe: custom property item in PropertyGrid Pin
Dragonfly_Lee5-Mar-09 18:22
Dragonfly_Lee5-Mar-09 18:22 
QuestionRun EXE from Remote machine in client machine... Pin
siva4555-Mar-09 4:09
siva4555-Mar-09 4:09 
AnswerRe: Run EXE from Remote machine in client machine... [modified] Pin
Mirko19805-Mar-09 4:35
Mirko19805-Mar-09 4:35 
GeneralRe: Run EXE from Remote machine in client machine... Pin
Tomas De Boever2-May-09 4:17
Tomas De Boever2-May-09 4:17 
AnswerRe: Run EXE from Remote machine in client machine... Pin
Yusuf5-Mar-09 5:48
Yusuf5-Mar-09 5:48 
Questionc# database Pin
Pooyan Behroozfar5-Mar-09 3:48
Pooyan Behroozfar5-Mar-09 3:48 
AnswerRe: c# database Pin
musefan5-Mar-09 3:56
musefan5-Mar-09 3:56 
AnswerRe: c# database Pin
Eddy Vluggen5-Mar-09 7:04
professionalEddy Vluggen5-Mar-09 7:04 
AnswerRe: c# database Pin
Dragonfly_Lee5-Mar-09 18:32
Dragonfly_Lee5-Mar-09 18:32 
QuestionC# Register DLL for COM Server Pin
Navneet Hegde5-Mar-09 3:41
Navneet Hegde5-Mar-09 3:41 
AnswerRe: C# Register DLL for COM Server Pin
Dave Kreskowiak5-Mar-09 5:45
mveDave Kreskowiak5-Mar-09 5:45 
AnswerRe: C# Register DLL for COM Server Pin
Dragonfly_Lee5-Mar-09 20:01
Dragonfly_Lee5-Mar-09 20:01 
QuestionHow to activate Event Pin
E_Gold5-Mar-09 2:44
E_Gold5-Mar-09 2:44 
AnswerRe: How to activate Event Pin
musefan5-Mar-09 2:50
musefan5-Mar-09 2:50 
AnswerRe: How to activate Event Pin
Pete O'Hanlon5-Mar-09 2:56
mvePete O'Hanlon5-Mar-09 2:56 
GeneralRe: How to activate Event Pin
Christian Graus5-Mar-09 9:53
protectorChristian Graus5-Mar-09 9:53 
AnswerRe: How to activate Event PinPopular
Nagy Vilmos5-Mar-09 3:03
professionalNagy Vilmos5-Mar-09 3:03 
WTF?

For some unknown reason, I'll answer this. You do not 'activate' an event. Not in C#, not in any language. An event is fired to handle an 'external' action. In your example, the Form_Load event is fired when (can you guess?) a form is loaded.
What you probably want, but due to synaptic damage failed to state, is to have the same outcome when either the form is loaded or a button upon it is pressed. There are many ways to do it, but the one that 55+ IQ holders would consider is called, and I'm sorry it's a big word, 'refactoring'. This means taking the code that you want to run from two different places and putting in its own method. Then tyou can call it from anywhere.



Panic, Chaos, Destruction.
My work here is done.

AnswerRe: How to activate Event Pin
DaveyM695-Mar-09 3:05
professionalDaveyM695-Mar-09 3:05 
GeneralRe: How to activate Event Pin
Nagy Vilmos5-Mar-09 3:06
professionalNagy Vilmos5-Mar-09 3:06 
GeneralRe: How to activate Event Pin
DaveyM695-Mar-09 3:09
professionalDaveyM695-Mar-09 3:09 
GeneralRe: How to activate Event Pin
Yusuf5-Mar-09 5:51
Yusuf5-Mar-09 5:51 
QuestionSystem.Net.Mail question Pin
dptalt5-Mar-09 2:39
dptalt5-Mar-09 2:39 
AnswerRe: System.Net.Mail question Pin
Rutvik Dave5-Mar-09 3:39
professionalRutvik Dave5-Mar-09 3:39 
Question[Message Deleted] Pin
anupmadathil5-Mar-09 2:25
anupmadathil5-Mar-09 2:25 
AnswerRe: How to send Email using MS Exchange. PinPopular
Nagy Vilmos5-Mar-09 3:06
professionalNagy Vilmos5-Mar-09 3:06 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.