Results 1 to 3 of 3

Thread: Code VB : วิธีการ ตั้ง Hotkey โดยใช้ GetAsyncKeyState นะครับ

  1. #1
    Junior Member
    Join Date
    Jul 2010
    Posts
    24


    Code VB : วิธีการ ตั้ง Hotkey โดยใช้ GetAsyncKeyState นะครับ

    สำหรับคนที่หา วิธี ตั้ง Hotkey โดยใช้ GetAsyncKeyState นะครับ ดูตัวอย่าง ภายในกระทู้นี้ได้นะ
    ลองศึกษา ดูนะครับ ไม่ยาก

    Code ที่ผมใช้นะ

    Unhidden Content - Enjoy The View!
    ก่อนอื่นเลย ตั้ง Private ก่อน
    Code:
    Private Declare Function GetAsyncKeyState Lib "USER32" (ByVal Key As Long) As Integer
    ต่อไปก้มา ใส่คำสั่งใน Timer นะครับ ตาม Code นี้เลย

    Code:
    Dim hotkey As Boolean
    hotkey = GetAsyncKeyState(Keys.F10)
    if hotkey = True then
    Msg("Yes")
    End if
    *ควรสั่งเริ่ม Timer ไว้ด้วยนะครับ
    *Code นี้ผม ยกตัวอย่างให้ เฉยๆ ลองเอาไปดัดแปลง หรือ เพิ่มเติม เอาเลย ครับผม ไม่ยาก

  2. #2
    Junior Member
    Join Date
    Jul 2010
    Posts
    7


    Wink

    พยามต่อไปนะคับ เป็นกำลังใจให้นะคับ ผมอยากให้หาบทความอื่นมาอีกนะคับ อยากอ่านมากๆคับ อะไรก็ได้ที่มีความรู้อะคับ นะคับ ........................................
    Last edited by Smily; 12-08-2010 at 11:18 PM.

  3. #3


    ดีครับพี่หนุ่มผมกำลัง จะหาอยู่พอดีเลย วิธีตั้ง hotkey นิ พอดีจะทำโปรเเกรม

    เป็นกำลังใจให้เช่นกันครับ เป็นข้อมูลที่ดีมากครับ

Similar Threads

  1. Replies: 3
    Last Post: 01-08-2010, 10:21 PM
  2. Replies: 3
    Last Post: 01-08-2010, 03:05 PM
  3. สอบถามฟังชัน GetAsyncKeyState
    By natsu in forum C/C++,C#,VC++,MFC,Win32
    Replies: 1
    Last Post: 09-07-2009, 12:39 AM
  4. Replies: 0
    Last Post: 17-10-2007, 10:24 AM
  5. Replies: 0
    Last Post: 12-09-2007, 07:30 PM

Members who have read this thread : 0

Actions : (View-Readers)

There are no names to display.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •