الفريق العربي للبرمجةأرشيف المنتديات · 2000 – 2023
نسخة أرشيفية للقراءة فقط — التسجيل والمشاركة مغلقان، والمحتوى محفوظ كما كان.

طريقة التحكم ب key event على textbox

مغلق
بدأه IGBSpeed في 27 أبريل 2006 · 2 رد · 530 مشاهدة · في Microsoft Visual Basic.NET
مشاركة: واتساب X فيسبوك تيليجرام
#1 صاحب الموضوع

إسناداً للمشاركات السابقة بخصوص هذا الموضوع ورغبةً مني بوضع مثال مباشر عن هذا الموضوع لتتم مناقشته .

جرب بعد تشغيل البرنامج الضغط على مفتاح ( enter ) طبعاً (ctrl+Enter) لإضافة سطر جديد أو مفتاح الهروب أو مفتاح المسح وأنظر ما ذا يحدث .

أليكم الثال في المرفقات .

علماً بوجود مشاركات سابقة وخاصةً بهذا الموضوع (مثلاً طريقة إيقاف تشغيل Ctrl+Alt+Delete ) .. إلخ .

هذا المثال مقتبس من مكتبة msdn وأخذت للوصول إليه ساعتين من العناء الكبير لذا حبيت أن أشارككم فيه .

KeyEvent.rar

#2

لم أستطع إلى الآن تحقيق ماهو مشروح بصفحة مكتبة مايكروسوفت حول هذا الموضوع وهذا الشرح :

اقتباس
UnregisterHotKey Function

--------------------------------------------------------------------------------

The UnregisterHotKey function frees a hot key previously registered by the calling thread.

Syntax

BOOL UnregisterHotKey(          HWND hWnd,

    int id

);

Parameters

hWnd

[in] Handle to the window associated with the hot key to be freed. This parameter should be NULL if the hot key is not associated with a window.

id

[in] Specifies the identifier of the hot key to be freed.

Return Value

If the function succeeds, the return value is nonzero.

If the function fails, the return value is zero. To get extended error information, call GetLastError.

Remarks

For an example, see Displaying Keyboard Input.

Function Information

Minimum DLL Version user32.dll

Header Declared in Winuser.h, include Windows.h

Import library User32.lib

Minimum operating systems Windows 95, Windows NT 3.1

Unicode Implemented as Unicode version.

وهذه هي الوصلة :

صفحة مايروسوفت في تعطيل مفاتيح الوصول

وتوجد العديد من الدوال الجاهزة تحت هذا المسار :

MSDN Home > MSDN Library > Win32 and COM Development > User Interface > Windows User Interface > User Input > Keyboard Input >

#3

إبحث عن موضوع (Disable HotKeys ) .

الرجاء المساعدة لمن قد وصل إلى الحل قبلي ....

هذا الموضوع مغلق.

مواضيع مشابهة