التنبيهات التالية ظهرت :
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 864 - File: showthread.php PHP 7.4.33 (Linux)
File Line Function
/showthread.php 864 errorHandler->error



تقييم الموضوع :
  • 0 أصوات - بمعدل 0
  • 1
  • 2
  • 3
  • 4
  • 5
[كود] تعديل Control.WndProc Method
#1
vb.net كود
كود :
Sub CustomPaint()
        CreateGraphics.DrawRectangle(New Pen(Color.FromArgb(0, 0, 0)), New Rectangle(1, 1, Width - 3, Height - 3))
        CreateGraphics.DrawRectangle(New Pen(Color.FromArgb(90, 90, 90)), New Rectangle(0, 0, Width - 1, Height - 1))
    End Sub
C# يوجد خطأ
كود :
public void CustomPaint()
{
    CreateGraphics.DrawRectangle(new Pen(Color.FromArgb(0, 0, 0)), new Rectangle(1, 1, Width - 3, Height - 3));
    CreateGraphics.DrawRectangle(new Pen(Color.FromArgb(90, 90, 90)), new Rectangle(0, 0, Width - 1, Height - 1));
}
الخطأ فى
CreateGraphics.DrawRectangle(new Pen(Color.FromArgb(0, 0, 0)), new Rectangle(1, 1, Width - 3, Height - 3));
CreateGraphics.DrawRectangle(new Pen(Color.FromArgb(90, 90, 90)), new Rectangle(0, 0, Width - 1, Height - 1));
vb.net

كود :
Protected Overrides Sub WndProc(ByRef m As System.Windows.Forms.Message)
        MyBase.WndProc(m)
        If m.Msg = 15 Then CustomPaint()
    End Sub
C#
كود :
protected override void WndProc(ref System.Windows.Forms.Message m)
    {
        base.WndProc(m);
        if (m.Msg == 15)
        {
            CustomPaint();
        }
    }
الخطأ فى base.WndProc(m);
الرد }}}
تم الشكر بواسطة:


الردود في هذا الموضوع
تعديل Control.WndProc Method - بواسطة أسامة - 10-09-14, 11:32 PM
RE: تعديل - بواسطة أسامة - 11-09-14, 02:50 AM
RE: تعديل - بواسطة vbnet - 11-09-14, 03:05 PM
RE: تعديل Control.WndProc Method - بواسطة أسامة - 11-09-14, 05:10 PM
RE: تعديل Control.WndProc Method - بواسطة vbnet - 11-09-14, 09:28 PM
RE: تعديل Control.WndProc Method - بواسطة أسامة - 11-09-14, 10:23 PM
RE: تعديل Control.WndProc Method - بواسطة vbnet - 11-09-14, 11:31 PM


التنقل السريع :


يقوم بقرائة الموضوع: بالاضافة الى ( 1 ) ضيف كريم