|
C# DateTimePicker BackColor
|
|||
---|---|---|---|
#18+
Скажите пожалуйста, как научить DateTimePicker работать с BackColor? Заранее благодарен. ... |
|||
:
Нравится:
Не нравится:
|
|||
14.02.2014, 09:33 |
|
C# DateTimePicker BackColor
|
|||
---|---|---|---|
#18+
вот здесь юзер тоже тем же занят http://www.sql.ru/forum/1077394/datetimepicker-dobavit-svoystva-backcolor ... |
|||
:
Нравится:
Не нравится:
|
|||
14.02.2014, 13:20 |
|
C# DateTimePicker BackColor
|
|||
---|---|---|---|
#18+
Winnipuh, сделал это следующим образом автор protected override void OnPaint(PaintEventArgs e) { Color textColor = Color.Black; e.Graphics.FillRectangle(new SolidBrush(_backColor), new Rectangle(0, 0, this.ClientSize.Width - SystemInformation.VerticalScrollBarWidth - 15, this.ClientSize.Height)); TextRenderer.DrawText(e.Graphics, Text, Font, ClientRectangle, textColor, Color.Empty, TextFormatFlags.VerticalCenter); } public void MyBackColor(Color clr) { this.SetStyle(ControlStyles.UserPaint | ControlStyles.OptimizedDoubleBuffer, true); this.Invalidate(); } Но в этом случае пропадает кнопочка справа - открытие календарика (хотя работет). Как сделать так, чтобы кнопочка не пропадала? ... |
|||
:
Нравится:
Не нравится:
|
|||
14.02.2014, 13:58 |
|
|
start [/forum/topic.php?fid=20&fpage=128&tid=1403273]: |
0ms |
get settings: |
7ms |
get forum list: |
13ms |
check forum access: |
3ms |
check topic access: |
3ms |
track hit: |
40ms |
get topic data: |
13ms |
get forum data: |
3ms |
get page messages: |
44ms |
get tp. blocked users: |
2ms |
others: | 11ms |
total: | 139ms |
0 / 0 |