Click here to Skip to main content
15,901,505 members
Home / Discussions / C#
   

C#

 
GeneralRe: DoubleClick Event on a Label Pin
Heath Stewart24-Nov-04 8:44
protectorHeath Stewart24-Nov-04 8:44 
Generalproblem with GraphicsPath Pin
bernd.salewski24-Nov-04 7:49
bernd.salewski24-Nov-04 7:49 
GeneralRe: problem with GraphicsPath Pin
Heath Stewart24-Nov-04 9:01
protectorHeath Stewart24-Nov-04 9:01 
GeneralRe: problem with GraphicsPath Pin
bernd.salewski24-Nov-04 9:14
bernd.salewski24-Nov-04 9:14 
GeneralRe: problem with GraphicsPath Pin
Heath Stewart24-Nov-04 10:06
protectorHeath Stewart24-Nov-04 10:06 
GeneralRe: problem with GraphicsPath Pin
bernd.salewski24-Nov-04 10:51
bernd.salewski24-Nov-04 10:51 
GeneralI found my mistake!!! Pin
bernd.salewski24-Nov-04 11:50
bernd.salewski24-Nov-04 11:50 
Generalsummations Pin
cma2324-Nov-04 7:18
cma2324-Nov-04 7:18 
GeneralRe: summations Pin
Heath Stewart24-Nov-04 8:45
protectorHeath Stewart24-Nov-04 8:45 
GeneralRe: summations Pin
cma2324-Nov-04 9:16
cma2324-Nov-04 9:16 
GeneralRe: summations Pin
Heath Stewart24-Nov-04 10:09
protectorHeath Stewart24-Nov-04 10:09 
GeneralRemoting Problems ... Pin
Paebbels24-Nov-04 6:23
Paebbels24-Nov-04 6:23 
GeneralRe: Remoting Problems ... Pin
Paebbels25-Nov-04 9:07
Paebbels25-Nov-04 9:07 
QuestionFind HttpChannel??? Pin
Snowjim24-Nov-04 4:42
Snowjim24-Nov-04 4:42 
AnswerRe: Find HttpChannel??? Pin
Stefan Troschuetz24-Nov-04 5:10
Stefan Troschuetz24-Nov-04 5:10 
GeneralRe: Find HttpChannel??? Pin
Snowjim24-Nov-04 5:19
Snowjim24-Nov-04 5:19 
GeneralRe: Find HttpChannel??? Pin
Stefan Troschuetz24-Nov-04 5:26
Stefan Troschuetz24-Nov-04 5:26 
GeneralRe: Find HttpChannel??? Pin
Heath Stewart24-Nov-04 5:40
protectorHeath Stewart24-Nov-04 5:40 
GeneralRe: Find HttpChannel??? Pin
Stefan Troschuetz24-Nov-04 7:51
Stefan Troschuetz24-Nov-04 7:51 
GeneralRe: Find HttpChannel??? Pin
Heath Stewart24-Nov-04 10:19
protectorHeath Stewart24-Nov-04 10:19 
GeneralRe: Find HttpChannel??? Pin
Stefan Troschuetz24-Nov-04 21:05
Stefan Troschuetz24-Nov-04 21:05 
Generalchange border width and color of panel Pin
yonitgil24-Nov-04 3:27
yonitgil24-Nov-04 3:27 
Hi,
I want to change the color and width of my panel's border.
I created a class which inherits from panel, and override the onPaint() method. In that method, I called to ControlPaint.DrawBorder().
When I debug it,I see that it enter the function and perform the ControlPaint.DrawBorder(), but I don't see any change in the color of width of the panel border.
I attached the code.

Please help..
thanks
y.


public class BorderPanel : Panel
{

private Color m_borderColor;// The color of the border
private int m_borderWidth;//the width of the border
private BorderStyle m_BorderStyle;//the border style

public BorderPanel()
{
}



protected override void OnPaint(PaintEventArgs e)

{

base.OnPaint(e);

int borderWidth = 1;

Color borderColor = Color.Blue;

ControlPaint.DrawBorder(e.Graphics, new Rectangle(100, 100, 500, 100), borderColor,

borderWidth, ButtonBorderStyle.Solid, borderColor, 15,

ButtonBorderStyle.Solid, borderColor, 15, ButtonBorderStyle.Solid,

borderColor, 15, ButtonBorderStyle.Solid);



}

//Property of the border color

public Color BorderColor
{
get
{
return m_borderColor;
}
set
{
m_borderColor = value;
}
}

//Property of the border width

public int BorderWidth
{
get
{
return m_borderWidth;
}
set
{
m_borderWidth = value;
}
}

//Property of the border Style

public BorderStyle PanelBorderStyle
{
get
{
return m_BorderStyle;
}
set
{
m_BorderStyle = value;

this.BorderStyle = value;
}
}
GeneralRe: change border width and color of panel Pin
Heath Stewart24-Nov-04 10:43
protectorHeath Stewart24-Nov-04 10:43 
GeneralRe: change border width and color of panel Pin
yonitgil27-Dec-04 21:45
yonitgil27-Dec-04 21:45 
GeneralRe: change border width and color of panel Pin
Heath Stewart28-Dec-04 5:11
protectorHeath Stewart28-Dec-04 5:11 

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.