Author: Eran
Date: 07:32:49 01/29/01
I plan to create a new chess program based on MFC in Visual C++ 6 Pro. Though I
am a beginner, I try to develop both the interface and the chess engine.
I knew how to put a chessboard picture on a dialog box using picture control in
the Dialog Editor. Besides, the dialog box could become like an overlapped
mainframe window. However, I was not sure whether the dialog box was the right
place to hold the chessboard picture. So, I tried to put it on a frame window
instead of the dialog box. Unfortunately, I wrestled with the problem of how to
put the picture on it. Moreover, I could not find a solution in the MSDN Library
either. Further, I tried the code below but still nothing worked out in my
programming.
void CMyWinApp::OnFileNew()
{
LoadBitmap(AfxGetResourceHandle(), MAKEINTRESOURCE(IDB_CHESSBOARD));
BitBlt(NULL,0,0,450,450,NULL,0,0,SRCCOPY);
}
If you know how, please inform me. I will appreciate it.
It seems to me that the dialog box is the only place to hold any picture, but I
am not sure whether I am right. What will you tell me? Besides, I am aware that
Visual C++ is not nice with interface development, but it is excellent with
chess engine development due to the faster optimizing compiler.
Furthermore, I do not know for sure whether the MFC is also designed for chess
software development. Isn't it?
Anyway, some CCC members told me that it was much better to develop chess engine
program in the window console. So I could spend more time only on chess engine
development. I understand that, but I still love to create both interface and
chess engine and I do not mind hard work for a long time. I will try it - it is
worth a try. ;)
I am eager to read your follow-up posts.
Your help is greatly appreciated.
Thanks in advance,
Eran
This page took 0 seconds to execute
Last modified: Thu, 15 Apr 21 08:11:13 -0700
Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.