Hi, works like a charm, here's some code if anyone wants to try it: //Keypad settings #define KEYPAD_X 550 //keypad left border #define KEYPAD_Y 100 //keypad top #define KEYPAD_WIDTH 225 // #define KEYPAD_HEIGHT 300 // #define GLOBALVALUE_X 550 #define GLOBALVALUE_Y 60 #define GLOBALVALUE_WIDTH 225 #define GLOBALVALUE_HEIGHT 40 //variables needed: //globals keypad GButtonObject keypadGlobalsButton[12]; GHandle keypadGlobalsButtonHandle[12]; GSourceHandle keypadGlobalsButtonSource[12]; char* keypadGlobalsStrings[12] = {"1","2","3","4","5","6","7","8","9","BACK","0","CLR"}; GListener keypadGlobalsCB; //the variable we're editing static uint32_t globalEditValue = 0; font_t fontLarger; void printGlobalVar(void){ char globalValueText[12]; chprintftostring(globalValueText, "%u", globalEditValue); gdispFillStringBox(GLOBALVALUE_X, GLOBALVALUE_Y, GLOBALVALUE_WIDTH, GLOBALVALUE_HEIGHT, globalValueText, fontLarger, Yellow, DarkGreen, justifyCenter); gdispDrawBox(GLOBALVALUE_X, GLOBALVALUE_Y, GLOBALVALUE_WIDTH, GLOBALVALUE_HEIGHT, Green); } //The shared button handler void keypadGlobalsButtonHandler(void *param, GEvent *pe){ GHandle pressed = ((GEventGWinButton *)pe)->button; uint8_t i = 0; for(i = 0; i < 12; i++){ if(pressed == keypadGlobalsButtonHandle[i]){ break; } } if(i == 9){//backspace .. divide by 10 globalEditValue /= 10; }else if(i == 11){//clear globalEditValue = 0; }else if(i < 9){//x = 1..9, y(n+1) = 10*y(n) + x globalEditValue = 10 * globalEditValue + i + 1; }else if(i == 10){//x = 0, y(n+1) = 10*y(n) globalEditValue *= 10; } printGlobalVar(); } //alloc of the buttons void createGlobalsKeypadButtons(void){ uint8_t x, y, i = 0; fontLarger = gdispOpenFont("Larger Double"); geventListenerInit(&keypadGlobalsCB); keypadGlobalsCB.callback = &keypadGlobalsButtonHandler; //draw keypad: 0..9, backsp, "." and assign button for(y = 0; y < 4; y++){ for(x = 0; x < 3; x++){ keypadGlobalsButtonHandle[i] = gwinCreateButton(&keypadGlobalsButton[i], KEYPAD_X + x * 75 + 3, KEYPAD_Y + y * 75 + 3, 70, 70, fontLarger, GBTN_NORMAL); gwinSetButtonText(keypadGlobalsButtonHandle[i], keypadGlobalsStrings[i], FALSE); keypadGlobalsButtonSource[i] = gwinGetButtonSource(keypadGlobalsButtonHandle[i]); geventAttachSource(&keypadGlobalsCB, keypadGlobalsButtonSource[i], 0);//attach listener gwinAttachButtonMouse(keypadGlobalsButtonHandle[i], 0); i++; } } } //buttons de-activation void disableGlobalsKeypad(void){ uint8_t i = 0; GButtonObject *gb; for(i = 0; i < 12; i++){ if(keypadGlobalsButtonHandle[i] != NULL){ gb = &keypadGlobalsButton[i]; gb->gwin.enabled = FALSE; } } } //buttons activation void enableGlobalsKeypad(uint8_t draw){ uint8_t i = 0; GButtonObject *gb; if(draw == TRUE){//start with a lightgrey square background gdispFillArea(KEYPAD_X, KEYPAD_Y, KEYPAD_WIDTH, KEYPAD_HEIGHT, LightGray); } for(i = 0; i < 12; i++){ if(keypadGlobalsButtonHandle[i] != NULL){ gb = &keypadGlobalsButton[i]; gb->gwin.enabled = TRUE; if(draw == TRUE){ gwinButtonDraw(keypadGlobalsButtonHandle[i]); } } } } In your init code call createGlobalsKeypadButtons(); followed by disableGlobalsKeypad(); The buttons are allocated, listening and calling the callback but they're not drawn - disableGlobalsKeypad() disables them altogether without destroying them. When you're ready to draw them you clear the screen and call enableGlobalsKeypad(TRUE); BTW, everything is called xxxGlobalsxxx because I use this to edit and update global variables during runtime. If you have many buttons, don't forget to adjust GEVENT_MAX_SOURCE_LISTENERS. regards, Fred