728x90
[C#/VB.NET]UnregisterHotKey - 설정한 Hotkey의 해제
UnregisterHotKey함수는 RegisterHotKey함수로 설정한 Hotkey를 더이상 사용하지 않도록 해제하는 함수입니다.
Declare Function UnregisterHotKey Lib "user32" Alias "UnregisterHotKey" (ByVal hwnd As Integer, ByVal id As Integer) As Integer
▶VB.NET 선언
UnregisterHotKey(handle, id)
▶VB.NET 호출
[DllImport("user32.dll")]
private static extern int UnregisterHotKey(int hwnd, int id);
▶C# 선언
UnregisterHotKey(handle, id);
▶C# 호출
함수의 인수중 handle은 Hotkey를 해제하고자 하는 Form의 handle을 그리고 id는 Hotkey를 설정할때의 id값을 그대로 전달하면 됩니다.
728x90
'자료' 카테고리의 다른 글
[C#/VB.NET]GetAsyncKeyState - 현재 Key상태 확인 (0) | 2021.03.17 |
---|---|
[C#/VB.NET]GetKeyState - 해당 Key가 눌려졌는지에 대한 상태값 반환 (0) | 2021.03.17 |
[C#/VB.net]RegisterHotKey - Windows Hotkey 핫키 설정 (0) | 2021.03.17 |
[C#/VB.NET] 한글을 자음 모음으로 나누기 & 합치기 (0) | 2021.02.21 |
[C#/ VB.NET] [API] 한/영 키 상태 값 구하기 (0) | 2021.02.21 |