Click here to Skip to main content
15,063,166 members
Home / Discussions / C#
   

C#

 
QuestionHow to make an inactive window work and respond to buttons (C# .NET windows forms) Pin
Marcin Rajczakowski23-Aug-21 10:31
MemberMarcin Rajczakowski23-Aug-21 10:31 
AnswerRe: How to make an inactive window work and respond to buttons (C# .NET windows forms) Pin
BillWoodruff23-Aug-21 11:20
mveBillWoodruff23-Aug-21 11:20 
GeneralInterfaces with code in them Pin
Rob Philpott20-Aug-21 0:22
MemberRob Philpott20-Aug-21 0:22 
GeneralRe: Interfaces with code in them Pin
Richard Deeming20-Aug-21 0:40
mveRichard Deeming20-Aug-21 0:40 
GeneralRe: Interfaces with code in them Pin
Rob Philpott20-Aug-21 0:55
MemberRob Philpott20-Aug-21 0:55 
GeneralRe: Interfaces with code in them Pin
pkfox29-Aug-21 22:46
professionalpkfox29-Aug-21 22:46 
GeneralRe: Interfaces with code in them Pin
Gerry Schmitz20-Aug-21 6:48
mveGerry Schmitz20-Aug-21 6:48 
Questionthere I thought the days of CreateParams were over ... observation (tip ?) Pin
BillWoodruff17-Aug-21 12:34
mveBillWoodruff17-Aug-21 12:34 
using Framework 4.8, WinForms (classic).

I'm doing some complex run-time stuff with a TableLayoutPanel in a UserControl ... adding, replacing Controls, resizing columns, changing ColumnSpans ... even though the UserControl is double buffered, as well as its hosting Form (site) ... the usual bracketing in Suspend/Restore-Layout blocks does not prevent cascades of spastic stuttering.

But, one little dose of good old CreateParams
// insert at Class scope in your UserControl or sub-classed WinForm container

protected override CreateParams CreateParams
{
    get
    {
        CreateParams cp = base.CreateParams;
        cp.ExStyle = cp.ExStyle | 0x2000000;
        return cp;
    }
}
I thought that had gone extinct with other VB-heritage dinosaurs like 'DoEvents.
«The mind is not a vessel to be filled but a fire to be kindled» Plutarch


modified 18-Aug-21 2:05am.

AnswerRe: there I thought the days of CreateParams were over ... observation (tip ?) Pin
OriginalGriff19-Aug-21 9:02
mveOriginalGriff19-Aug-21 9:02 
GeneralRe: there I thought the days of CreateParams were over ... observation (tip ?) Pin
Richard Andrew x6419-Aug-21 9:26
professionalRichard Andrew x6419-Aug-21 9:26 
GeneralRe: there I thought the days of CreateParams were over ... observation (tip ?) Pin
BillWoodruff19-Aug-21 10:46
mveBillWoodruff19-Aug-21 10:46 
QuestionSystem.IndexOutOfRangeException Pin
ProgrammerT216-Aug-21 23:36
MemberProgrammerT216-Aug-21 23:36 
AnswerRe: System.IndexOutOfRangeException Pin
Ralf Meier16-Aug-21 23:43
professionalRalf Meier16-Aug-21 23:43 
AnswerRe: System.IndexOutOfRangeException Pin
OriginalGriff17-Aug-21 0:06
mveOriginalGriff17-Aug-21 0:06 
QuestionHow Linq determine the index of a list item? Pin
Alex Dunlop16-Aug-21 22:57
MemberAlex Dunlop16-Aug-21 22:57 
AnswerRe: How Linq determine the index of a list item? Pin
Richard Deeming16-Aug-21 23:09
mveRichard Deeming16-Aug-21 23:09 
QuestionC# interacting with Excel Pin
Ismael Oliveira 202116-Aug-21 13:15
MemberIsmael Oliveira 202116-Aug-21 13:15 
AnswerRe: C# interacting with Excel Pin
Richard Deeming16-Aug-21 21:36
mveRichard Deeming16-Aug-21 21:36 
GeneralRe: C# interacting with Excel Pin
Ismael Oliveira 202124-Aug-21 12:46
MemberIsmael Oliveira 202124-Aug-21 12:46 
AnswerRe: C# interacting with Excel Pin
Richard MacCutchan16-Aug-21 21:42
mveRichard MacCutchan16-Aug-21 21:42 
AnswerRe: C# interacting with Excel Pin
SpiveyC#7-Sep-21 1:44
MemberSpiveyC#7-Sep-21 1:44 
QuestionHow to merge cells in Excel using C# Pin
Ismael Oliveira 202112-Aug-21 12:43
MemberIsmael Oliveira 202112-Aug-21 12:43 
AnswerRe: How to merge cells in Excel using C# Pin
Richard MacCutchan12-Aug-21 21:35
mveRichard MacCutchan12-Aug-21 21:35 
GeneralRe: How to merge cells in Excel using C# Pin
Ismael Oliveira 202113-Aug-21 13:45
MemberIsmael Oliveira 202113-Aug-21 13:45 
GeneralRe: How to merge cells in Excel using C# Pin
Richard MacCutchan13-Aug-21 21:44
mveRichard MacCutchan13-Aug-21 21:44 

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.