Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Toolkit Pro
  New Posts New Posts RSS Feed - XTPReportControl and DockingPane
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

XTPReportControl and DockingPane

 Post Reply Post Reply
Author
Message
Atlantis View Drop Down
Newbie
Newbie
Avatar

Joined: 21 April 2005
Location: Russian Federation
Status: Offline
Points: 7
Post Options Post Options   Thanks (0) Thanks(0)   Quote Atlantis Quote  Post ReplyReply Direct Link To This Post Topic: XTPReportControl and DockingPane
    Posted: 03 May 2005 at 2:30am

I'm create docking pane with ReportControl

//MainFrame.h

CDockPaneWnd<CExXTPReportControl> m_wndReport;

CImageList m_imgListReport;

//MainFrame.cpp

int CMainFrame::OnCreate(LPCREATESTRUCT lpCreateStruct)

{

...

CXTPDockingPane* pwndPane3 = m_paneManager.CreatePane(IDR_PANE_REPORT, CRect(0, 0,200, 120), xtpPaneDockLeft);

...

}

LRESULT CMainFrame::OnDockingPaneNotify(WPARAM wParam, LPARAM lParam)

{

...

VERIFY(m_imgListReport.Create(16,16, ILC_COLOR24|ILC_MASK, 0, 1));

CBitmap bmp;

VERIFY(bmp.LoadBitmap(IDB_BMREPORT));

m_imgListReport.Add(&bmp, RGB(255, 0, 255));

m_wndReport.SetImageList(&m_imgListReport);

RECT rect = pPane->GetWindowRect();

//m_wndReport.Create(_T("STATIC"), NULL, WS_CHILD|WS_TABSTOP|WS_VISIBLE|WM_VSCROLL|WS_CLIPCHILDREN|WS _CLIPSIBLINGS, CRect(0, 0, 0, 0), this, 0);

ScreenToClient(&rect);

m_wndReport.Create(WS_CHILD|WS_TABSTOP|WS_VISIBLE|WM_VSCROLL , rect, this, 0);

m_wndReport.GetReportHeader()->AllowColumnRemove(FALSE);

//

// Add sample columns

//

m_wndReport.AddColumn(new CXTPReportColumn(COLUMN_ICON, _T(""), 18, FALSE, COLUMN_MAIL_ICON));

m_wndReport.AddColumn(new CXTPReportColumn(COLUMN_CHECK, _T(""), 18, FALSE, COLUMN_CHECK_ICON));

m_wndReport.AddColumn(new CXTPReportColumn(COLUMN_SUBJECT, _T("Subject"), 50));

COleDateTime odtSent(COleDateTime::GetCurrentTime());

COleDateTime odtCreated(COleDateTime::GetCurrentTime());

COleDateTime odtRecieved(COleDateTime::GetCurrentTime());

CString strMessage(" ");

CString strEmpty(" ");

m_wndReport.AddRecord(new CMessageRecord(msgImportanceNormal, FALSE, FALSE, _T("postmaster@mail.codejock.com"), _T("Undeliverable Mail"), odtSent, 7, TRUE, 5,

odtCreated, odtRecieved, strEmpty, strEmpty, strMessage,

strEmpty, strEmpty, strEmpty,

strEmpty, strEmpty,

strMessage)); odtSent -= 0.8;

...

}

How can i get WM_NOTIFY message to my Parent window, and how can i see scroll bars???

Thanks!

Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 06 May 2005 at 1:04am

Don't use CDockPaneWnd for ReportControl. It gives nothng, and hides ScrollBar.

call m_wndReport.SetOwner(this); to route messages to CMainFrame.

Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.188 seconds.