Click here to Skip to main content
15,885,546 members
Home / Discussions / C#
   

C#

 
AnswerRe: EntityFramework Disable Lazy loading Pin
Dave Kreskowiak5-Mar-15 10:10
mveDave Kreskowiak5-Mar-15 10:10 
GeneralMessage Removed Pin
5-Mar-15 11:02
professionalN_tro_P5-Mar-15 11:02 
GeneralRe: EntityFramework Disable Lazy loading Pin
Matt T Heffron5-Mar-15 12:00
professionalMatt T Heffron5-Mar-15 12:00 
GeneralMessage Removed Pin
5-Mar-15 11:24
professionalN_tro_P5-Mar-15 11:24 
GeneralRe: EntityFramework Disable Lazy loading Pin
Dave Kreskowiak5-Mar-15 12:09
mveDave Kreskowiak5-Mar-15 12:09 
AnswerRe: EntityFramework Disable Lazy loading Pin
Gerry Schmitz5-Mar-15 12:23
mveGerry Schmitz5-Mar-15 12:23 
Questionsolved: WinForms: What would make closing a MainForm require two Clicks on the ControlBox ? Pin
BillWoodruff5-Mar-15 2:08
professionalBillWoodruff5-Mar-15 2:08 
AnswerRe: WinForms: What would make closing a MainForm require two Clicks on the ControlBox ? Pin
Alan N5-Mar-15 2:58
Alan N5-Mar-15 2:58 
Ooh I think you have a owned form which isn't playing cricket! When the owner begins to close it tries to close the owned form but can't and then the owner's FormClosing event handler is supplied with a precancelled event args.

Rather than dispose of the utility form you should allow the form to close itself. In the example I assume that Hide should only occur when the user attempts to close the form manually.
C#
// Utility form close handler
protected override void OnFormClosing(FormClosingEventArgs e) {
  if (e.CloseReason == CloseReason.UserClosing) {
    Hide();
    e.Cancel = true;
  }
  base.OnFormClosing(e);
}


Alan.
GeneralRe: WinForms: What would make closing a MainForm require two Clicks on the ControlBox ? Pin
BillWoodruff5-Mar-15 3:50
professionalBillWoodruff5-Mar-15 3:50 
QuestionMemoryStream with PDF Pin
Jassim Rahma4-Mar-15 22:18
Jassim Rahma4-Mar-15 22:18 
AnswerRe: MemoryStream with PDF Pin
Pete O'Hanlon4-Mar-15 22:21
mvePete O'Hanlon4-Mar-15 22:21 
QuestionSend Mouse motion using sendMessage() Pin
Omarkkk4-Mar-15 22:10
Omarkkk4-Mar-15 22:10 
AnswerRe: Send Mouse motion using sendMessage() Pin
Gerry Schmitz4-Mar-15 23:52
mveGerry Schmitz4-Mar-15 23:52 
GeneralRe: Send Mouse motion using sendMessage() Pin
BillWoodruff5-Mar-15 3:48
professionalBillWoodruff5-Mar-15 3:48 
GeneralRe: Send Mouse motion using sendMessage() Pin
Gerry Schmitz5-Mar-15 5:27
mveGerry Schmitz5-Mar-15 5:27 
GeneralRe: Send Mouse motion using sendMessage() Pin
Pete O'Hanlon5-Mar-15 7:12
mvePete O'Hanlon5-Mar-15 7:12 
GeneralRe: Send Mouse motion using sendMessage() Pin
Gerry Schmitz5-Mar-15 11:00
mveGerry Schmitz5-Mar-15 11:00 
Questionhow to design E R D for language dictionary Pin
Member 112641494-Mar-15 19:02
Member 112641494-Mar-15 19:02 
AnswerRe: how to design E R D for language dictionary Pin
OriginalGriff4-Mar-15 19:43
mveOriginalGriff4-Mar-15 19:43 
AnswerRe: how to design E R D for language dictionary Pin
Pete O'Hanlon4-Mar-15 22:19
mvePete O'Hanlon4-Mar-15 22:19 
QuestionRunning forms in a thread in .NET Pin
landersohn694-Mar-15 8:45
landersohn694-Mar-15 8:45 
AnswerRe: Running forms in a thread in .NET PinPopular
Eddy Vluggen4-Mar-15 9:04
professionalEddy Vluggen4-Mar-15 9:04 
GeneralRe: Running forms in a thread in .NET Pin
landersohn694-Mar-15 9:18
landersohn694-Mar-15 9:18 
GeneralRe: Running forms in a thread in .NET Pin
Eddy Vluggen4-Mar-15 9:29
professionalEddy Vluggen4-Mar-15 9:29 
GeneralRe: Running forms in a thread in .NET Pin
landersohn694-Mar-15 10:53
landersohn694-Mar-15 10: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.