Click here to Skip to main content
15,924,402 members
Home / Discussions / C#
   

C#

 
GeneralRe: Question: how to access main Form component from another class ? Pin
Wendelius11-Jan-09 3:49
mentorWendelius11-Jan-09 3:49 
AnswerRe: Question: how to access main Form component from another class ? Pin
DaveyM6910-Jan-09 23:47
professionalDaveyM6910-Jan-09 23:47 
GeneralRe: Question: how to access main Form component from another class ? Pin
Mohammemd11-Jan-09 7:40
Mohammemd11-Jan-09 7:40 
AnswerRe: Question: how to access main Form component from another class ? Pin
DaveyM6911-Jan-09 0:13
professionalDaveyM6911-Jan-09 0:13 
GeneralRe: Question: how to access main Form component from another class ? Pin
Mohammemd11-Jan-09 7:42
Mohammemd11-Jan-09 7:42 
AnswerRe: Question: how to access main Form component from another class ? Pin
DaveyM6911-Jan-09 0:47
professionalDaveyM6911-Jan-09 0:47 
GeneralRe: Question: how to access main Form component from another class ? Pin
Mohammemd11-Jan-09 7:47
Mohammemd11-Jan-09 7:47 
GeneralRe: Question: how to access main Form component from another class ? Pin
DaveyM6911-Jan-09 8:29
professionalDaveyM6911-Jan-09 8:29 
You're welcome.

Mika's answer is basically the same, except he's making the main form a singleton instead of a seperate object that communicates with the main form.

His way is easiest if the main form is always going to be needed (which it normally is of course). I think a seperate 'Notifier' singleton class that raises events that the main form (or anything else for that matter which is a big plus) can subscribe to may, in the long term, have advantages - and is maybe a little more OO. Just like Mika's solution, it can have properties and methods that will be accessisble to all objects in your application.

Dave
BTW, in software, hope and pray is not a viable strategy. (Luc Pattyn)
Visual Basic is not used by normal people so we're not covering it here. (Uncyclopedia)

GeneralRe: Question: how to access main Form component from another class ? Pin
Wendelius11-Jan-09 12:01
mentorWendelius11-Jan-09 12:01 
GeneralRe: Question: how to access main Form component from another class ? Pin
Mohammemd11-Jan-09 18:32
Mohammemd11-Jan-09 18:32 
AnswerRe: Question: how to access main Form component from another class ? Pin
N a v a n e e t h11-Jan-09 21:45
N a v a n e e t h11-Jan-09 21:45 
QuestionHow should I design my project to support future plug-ins? Pin
Artmansoft10-Jan-09 19:47
Artmansoft10-Jan-09 19:47 
AnswerRe: How should I design my project to support future plug-ins? Pin
wjp_auhtm11-Jan-09 1:14
wjp_auhtm11-Jan-09 1:14 
GeneralRe: How should I design my project to support future plug-ins? Pin
Artmansoft11-Jan-09 1:50
Artmansoft11-Jan-09 1:50 
AnswerRe: How should I design my project to support future plug-ins? Pin
wjp_auhtm11-Jan-09 5:05
wjp_auhtm11-Jan-09 5:05 
GeneralRe: How should I design my project to support future plug-ins? Pin
Artmansoft11-Jan-09 18:17
Artmansoft11-Jan-09 18:17 
AnswerRe: How should I design my project to support future plug-ins? Pin
User 665811-Jan-09 2:25
User 665811-Jan-09 2:25 
GeneralRe: How should I design my project to support future plug-ins? Pin
Artmansoft11-Jan-09 18:19
Artmansoft11-Jan-09 18:19 
AnswerRe: How should I design my project to support future plug-ins? Pin
Luis Alonso Ramos11-Jan-09 9:33
Luis Alonso Ramos11-Jan-09 9:33 
GeneralRe: How should I design my project to support future plug-ins? Pin
Artmansoft11-Jan-09 18:19
Artmansoft11-Jan-09 18:19 
QuestionList view in C# .net 2003 Pin
ananthvivek10-Jan-09 18:20
ananthvivek10-Jan-09 18:20 
AnswerRe: List view in C# .net 2003 Pin
ananthvivek10-Jan-09 19:57
ananthvivek10-Jan-09 19:57 
GeneralRe: List view in C# .net 2003 Pin
Wendelius10-Jan-09 21:13
mentorWendelius10-Jan-09 21:13 
GeneralRe: List view in C# .net 2003 Pin
Luis Alonso Ramos11-Jan-09 9:28
Luis Alonso Ramos11-Jan-09 9:28 
GeneralRe: List view in C# .net 2003 Pin
ananthvivek12-Jan-09 21:01
ananthvivek12-Jan-09 21:01 

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.