Trying to create a button with the default behavior i.e when the user press ENTER, the button is fired.
Created the button with WS_TABSTOP style and sent it the BM_SETSTYLE message with BS_DEFPUSHBUTTON has WPARAM parameter but it still not working.

HWND hwnd_Ok = CreateWindow("button", "Ok", WS_VISIBLE | WS_CHILD | WS_TABSTOP, 285, 195, 70, 25, hwnd, (HMENU)OK_BUTTON, NULL, NULL);

SendMessage(hwnd_Ok, BM_SETSTYLE, (WPARAM)BS_DEFPUSHBUTTON, TRUE);