Click here to Skip to main content
15,891,763 members
Home / Discussions / C#
   

C#

 
GeneralRe: LINQ to Entities Pin
OriginalGriff15-Feb-11 21:18
mveOriginalGriff15-Feb-11 21:18 
GeneralRe: LINQ to Entities Pin
PIEBALDconsult16-Feb-11 1:40
mvePIEBALDconsult16-Feb-11 1:40 
GeneralRe: LINQ to Entities Pin
OriginalGriff16-Feb-11 2:23
mveOriginalGriff16-Feb-11 2:23 
GeneralRe: LINQ to Entities Pin
PIEBALDconsult16-Feb-11 13:23
mvePIEBALDconsult16-Feb-11 13:23 
GeneralRe: LINQ to Entities Pin
OriginalGriff16-Feb-11 22:17
mveOriginalGriff16-Feb-11 22:17 
AnswerRe: LINQ to Entities Pin
Not Active15-Feb-11 10:07
mentorNot Active15-Feb-11 10:07 
QuestionSingleton Form updated from main Form - Object Reference Error Pin
Edunt15-Feb-11 4:36
Edunt15-Feb-11 4:36 
AnswerRe: Singleton Form updated from main Form - Object Reference Error Pin
Luc Pattyn15-Feb-11 5:20
sitebuilderLuc Pattyn15-Feb-11 5:20 
Something is wrong. Your child form gets created inside GetInstance() yet you never call that method, instead you refer directly to the frm member.

This is what you could do:
- make frm private;
- add a public Frm property, basically doing what GetInstance() did (note the case difference);
- get rid of GetInstance();
- whenever the parent form needs the child form, use frmChildForm.Frm

The better alternative would be to:
- make frm private;
- add a child member to your parent form;
- set it to the result of GetInstance() before using it, then use it instead of frmChildForm.frm

Same result, fewer public members, hence more reliable code.

Smile | :)
Luc Pattyn [Forum Guidelines] [My Articles] Nil Volentibus Arduum
Please use <PRE> tags for code snippets, they preserve indentation, improve readability, and make me actually look at the code.

GeneralRe: Singleton Form updated from main Form - Object Reference Error Pin
Edunt15-Feb-11 9:28
Edunt15-Feb-11 9:28 
GeneralRe: Singleton Form updated from main Form - Object Reference Error Pin
Luc Pattyn15-Feb-11 10:10
sitebuilderLuc Pattyn15-Feb-11 10:10 
AnswerRe: Singleton Form updated from main Form - Object Reference Error Pin
musefan15-Feb-11 5:26
musefan15-Feb-11 5:26 
GeneralRe: Singleton Form updated from main Form - Object Reference Error Pin
Edunt15-Feb-11 9:45
Edunt15-Feb-11 9:45 
AnswerRe: Singleton Form updated from main Form - Object Reference Error Pin
_Erik_15-Feb-11 5:47
_Erik_15-Feb-11 5:47 
AnswerRe: Singleton Form updated from main Form - Object Reference Error [modified] Pin
Edunt15-Feb-11 10:07
Edunt15-Feb-11 10:07 
Questionremove duplicates from list collection Pin
arkiboys15-Feb-11 0:40
arkiboys15-Feb-11 0:40 
AnswerRe: remove duplicates from list collection PinPopular
Pravin Patil, Mumbai15-Feb-11 0:53
Pravin Patil, Mumbai15-Feb-11 0:53 
GeneralRe: remove duplicates from list collection Pin
arkiboys15-Feb-11 0:57
arkiboys15-Feb-11 0:57 
GeneralRe: remove duplicates from list collection Pin
musefan15-Feb-11 1:28
musefan15-Feb-11 1:28 
GeneralRe: remove duplicates from list collection Pin
PIEBALDconsult15-Feb-11 1:49
mvePIEBALDconsult15-Feb-11 1:49 
GeneralRe: remove duplicates from list collection Pin
musefan15-Feb-11 1:58
musefan15-Feb-11 1:58 
GeneralRe: remove duplicates from list collection Pin
PIEBALDconsult15-Feb-11 4:07
mvePIEBALDconsult15-Feb-11 4:07 
GeneralRe: remove duplicates from list collection Pin
musefan15-Feb-11 4:12
musefan15-Feb-11 4:12 
GeneralRe: remove duplicates from list collection Pin
PIEBALDconsult15-Feb-11 4:31
mvePIEBALDconsult15-Feb-11 4:31 
GeneralRe: remove duplicates from list collection Pin
Pravin Patil, Mumbai15-Feb-11 1:50
Pravin Patil, Mumbai15-Feb-11 1:50 
GeneralRe: remove duplicates from list collection Pin
musefan15-Feb-11 1:53
musefan15-Feb-11 1:53 

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.