Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

GetWindowRect

Status
Not open for further replies.

nbgoku

Programmer
May 25, 2004
108
US
BOOL CtabDlg::OnInitDialog()
{
//blah blah
// TODO: Add extra initialization here
CtabDlg f;
LPRECT t;
f.GetWindowRect(t);
UpdateData(0);
return TRUE; // return TRUE unless you set the focus to a control
}



it doesnt seem to work, something wrong with my 't' i think, but im not sure, anyone know what could be wrong?
 
There is nothing to it. LPRECT is a pointer to a rect but it is pointing to garbage.

Try this

CRect rect;
GetWindowRect(&rect);
Matt
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top