how to find ID of Keypad Button

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • how to find ID of Keypad Button

    Hi


    I taken your sample notepad file for making a soft keypad.

    I try to add 'OK' key in keypad. When i Press 'OK' the current focused EDIT window data must be passed to called window(parent) EDIT widget.


    Now, how to find the ID of Button widget ID_BUTTON , since the code is increments ID_BUTTON + i ?

    C Source Code

    1. // Below is the call back function of keypad _cbKeyPad()
    2. #define ID_BUTTON (GUI_ID_USER + 0)
    3. ... case WM_CREATE: // // Create the keyboard buttons //
    4. for (i = 0; i < GUI_COUNTOF(_aButtonData); i++)
    5. {
    6. hButton = BUTTON_CreateEx(_aButtonData[i].xPos, _aButtonData[i].yPos, _aButtonData[i].xSize, _aButtonData[i].ySize, hWin, WM_CF_SHOW | WM_CF_HASTRANS, 0, ID_BUTTON + i);
    7. BUTTON_SetText(hButton, _aButtonData[i].acLabel); BUTTON_SetFocussable(hButton, 0);
    8. }
    9. break;
    Display All
    Images
    • softkeypad.png

      34 kB, 544×416, viewed 1,093 times

    The post was edited 2 times, last by vijitron ().