|
-
May 26th, 1999, 01:24 PM
#1
Problem when adding ScrollView into Dialog
I try to add the scrollview as contorl to the dialog.
I first derived a class from CScrollView (class charttest1 ublic CScrollView),
then I add charttest1.Create(..) in dialog's OnInitDialog(). the code of charttest1.Create(..)
is as following.
But it doesn't work, it can pass the compiler but always show error when running.
If somebody knows how, please tell me ASAP, thanks very very much.
BOOL charttest1::Create(const RECT& rect, CWnd* pParentWnd, UINT nID, CCreateContext* pContext)
{
// TODO: Add your specialized code here and/or call the base class
static CString classname=AfxRegisterWndClass(CS_HREDRAW|CS_VREDRAW);
return CWnd::Create(classname, NULL, WS_VISIBLE|WS_HSCROLL|WS_VSCROLL, rect, pParentWnd, NULL,NULL);
}
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|