Original Post
🔒 Locked
Windows structure problems
Advertisement
Well I talked to Keshin in the chat room and i tweaked the code a bunch so here it goes i don''t think i heard him correctly
anyways...
#include
#include
#define WIN32_LEAN_AND_MEAN
#ifdef DEBUG_MODE
printf("Debug mode is active!");
#endif
int WINAPI WinMain(HINSTANCE hinstance, HINSTANCE hPrevInstance,
LPSTR lpCmdLine, int nCmdShow)
{
typedef struct m_WndClass{
m_WndClass.hInstance = hInstance;
m_WndClass.hCursor = LoadCursor(NULL, IDC_ARROW);
m_WndClass.hIcon = LoadIcon(NULL, IDI_APPLICATION);
m_WndClass.hbrBackground = (HBRUSH) GetStockObject(BLACK_BRUSH);
m_WndClass.lpfnWndProc = lpWndProc;
m_WndClass.lpszClassName = WindowTitle.GetString();
m_WndClass.lpszMenuName = NULL;
m_WndClass.cbClsExtra = 0;
m_WndClass.cbWndExtra = 0;
m_WndClass.style = 0;
m_WindowTitle = WindowTitle.GetString();
/*UINT sizof(WNDCLASSEX);
UINT CS_OWNDC | CS_DBLCLKS;
WNDPROC lpfnWndProc;
int cbCl0;
int cbWndExtra*/0;
/*HANDLE hinstance;
HICON hIcon;
HCURSOR hCursor;
HBRUSH hbrBackground;
LPCTSTR lpszMenuName;
LPCTSTR lpszClassName;
HICON hIconSm;*/
} m_WndClass;
Okiees that''s it. The problem is after the structure, I don''t get why i can''t use the classes after the structure
. Oh well thanx!
--Axe
#include
#include
#define WIN32_LEAN_AND_MEAN
#ifdef DEBUG_MODE
printf("Debug mode is active!");
#endif
int WINAPI WinMain(HINSTANCE hinstance, HINSTANCE hPrevInstance,
LPSTR lpCmdLine, int nCmdShow)
{
typedef struct m_WndClass{
m_WndClass.hInstance = hInstance;
m_WndClass.hCursor = LoadCursor(NULL, IDC_ARROW);
m_WndClass.hIcon = LoadIcon(NULL, IDI_APPLICATION);
m_WndClass.hbrBackground = (HBRUSH) GetStockObject(BLACK_BRUSH);
m_WndClass.lpfnWndProc = lpWndProc;
m_WndClass.lpszClassName = WindowTitle.GetString();
m_WndClass.lpszMenuName = NULL;
m_WndClass.cbClsExtra = 0;
m_WndClass.cbWndExtra = 0;
m_WndClass.style = 0;
m_WindowTitle = WindowTitle.GetString();
/*UINT sizof(WNDCLASSEX);
UINT CS_OWNDC | CS_DBLCLKS;
WNDPROC lpfnWndProc;
int cbCl0;
int cbWndExtra*/0;
/*HANDLE hinstance;
HICON hIcon;
HCURSOR hCursor;
HBRUSH hbrBackground;
LPCTSTR lpszMenuName;
LPCTSTR lpszClassName;
HICON hIconSm;*/
} m_WndClass;
Okiees that''s it. The problem is after the structure, I don''t get why i can''t use the classes after the structure
--Axe
Thanx. Okay but the
.
.
.
.''s concern me, what would go in there?
ThanX gin!
--Axe
------------------------------
"If you died today, where would you go?" -Some guy in a foreign country.
"I''m a good person, I am going to heaven." -*laugh* The guy that thinks that being "good" has anything to do with it.
"Why doesn''t being good involve heaven?" -The concerned person on the street.
"Well, being good is important but anyone can be saved, regardless." -The guy again.
.
.
.
.''s concern me, what would go in there?
ThanX gin!
--Axe
------------------------------
"If you died today, where would you go?" -Some guy in a foreign country.
"I''m a good person, I am going to heaven." -*laugh* The guy that thinks that being "good" has anything to do with it.
"Why doesn''t being good involve heaven?" -The concerned person on the street.
"Well, being good is important but anyone can be saved, regardless." -The guy again.
None taken, I probably should. It''s just one of those things...well i know C...C++ isn''t THAT much different...is it...do i wanna waste the time learning it...*5 hrs later* I don''t think C++ will take too long cause not much changes...*opens the C++ book* WHOA! maybe it does...do i REALLY wanna learn it...
it''s just one of those do i really moods.
Thanx.
--Aximal
P.S. My compiler is a tad bit on the old side so not everything is compatable and that is one of the sources of my problems. I am going to get Watcom sometime in the future...
------------------------------
"If you died today, where would you go?" -Some guy in a foreign country.
"I''m a good person, I am going to heaven." -*laugh* The guy that thinks that being "good" has anything to do with it.
"Why doesn''t being good involve heaven?" -The concerned person on the street.
"Well, being good is important but anyone can be saved, regardless." -The guy again.
it''s just one of those do i really moods.
Thanx.
--Aximal
P.S. My compiler is a tad bit on the old side so not everything is compatable and that is one of the sources of my problems. I am going to get Watcom sometime in the future...
------------------------------
"If you died today, where would you go?" -Some guy in a foreign country.
"I''m a good person, I am going to heaven." -*laugh* The guy that thinks that being "good" has anything to do with it.
"Why doesn''t being good involve heaven?" -The concerned person on the street.
"Well, being good is important but anyone can be saved, regardless." -The guy again.
Topic Locked
This topic has been locked by a moderator. New replies are not allowed.
Sign in to reply to this topic.
Advertisement