The first problem is solved and for the second problem I'm posting this code:
Code:
LRESULT CALLBACK WndProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
{
HMENU hMenu, hEdit;
switch (message)
{
case WM_CREATE:
hMenu = LoadMenu (hInst, MAKEINTRESOURCE (IDR_MENU01));
SetMenu (hwnd, hMenu);
hEdit = CreateWindowEx(WS_EX_CLIENTEDGE, "EDIT", "", WS_CHILD |
WS_VISIBLE | WS_VSCROLL | WS_HSCROLL | ES_MULTILINE | ES_AUTOVSCROLL | ES_AUTOHSCROLL,
0, 0, 100, 100, hwnd, NULL, GetModuleHandle(NULL), NULL); // I copy/paste this from
//the tutorial I have on my disk,
//but this is for the edit control and
//I really do not know what to write for the ListBox control and
//I do not quite understand for the edit control either
return 0;
case WM_COMMAND:
hMenu = GetMenu (hwnd);
switch (LOWORD (wParam))
{
case IDM_FILE_EXIT:
SendMessage (hwnd, WM_CLOSE, 0, 0);
return 0;
case IDM_HELP_ABOUT:
DialogBox (hInst, MAKEINTRESOURCE (IDD_ABOUT), hwnd, About);
break;
}
break;
case WM_DESTROY:
PostQuitMessage (0);
return 0;
}
return DefWindowProc (hwnd, message, wParam, lParam);
}
My compiler is Visual C++ 5.0 on Win98.
Thank you for helping me.