Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Report Control
  New Posts New Posts RSS Feed - Some bugs in Report Control
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Some bugs in Report Control

 Post Reply Post Reply
Author
Message
aceproof View Drop Down
Newbie
Newbie


Joined: 24 March 2008
Location: Russian Federation
Status: Offline
Points: 9
Post Options Post Options   Thanks (0) Thanks(0)   Quote aceproof Quote  Post ReplyReply Direct Link To This Post Topic: Some bugs in Report Control
    Posted: 02 November 2009 at 4:33am
1. Function DoAutoVertScrollIfNeed does not work while dragging item
Quote
void CXTPReportControl::DoAutoVertScrollIfNeed(CPoint ptClick, CPoint pt)
{
     ...
     CXTPReportRow* pRow0 = m_arrScreenRows.GetAt(0);
     CXTPReportRow* pRow1 = m_arrScreenRows.GetAt(m_arrScreenRows.GetCount() - 1);

     ...
     int nDirection = 0;

     CRect rc0 = m_rcReportArea;
     CRect rc1 = m_rcReportArea;
     rc0.bottom = m_rcReportArea.top;// + 20;
     rc1.top = m_rcReportArea.bottom;// - 20;


     if (rc0.PtInRect(pt))
          nDirection = -1;
     else if (rc1.PtInRect(pt))
          nDirection = 1;
     ...
}

rc0 and rc1 is empty, nDirection = 0 all the time

2.
report.FocusSubItems(TRUE);

While pressing the "Left" key the selection of the Item don't change
Back to Top
mdoubson View Drop Down
Senior Member
Senior Member
Avatar

Joined: 17 November 2008
Status: Offline
Points: 1705
Post Options Post Options   Thanks (0) Thanks(0)   Quote mdoubson Quote  Post ReplyReply Direct Link To This Post Posted: 10 November 2009 at 12:25pm
You right, thanks. Remove // in red lines please
Back to Top
larryp View Drop Down
Groupie
Groupie


Joined: 15 January 2005
Location: United States
Status: Offline
Points: 61
Post Options Post Options   Thanks (0) Thanks(0)   Quote larryp Quote  Post ReplyReply Direct Link To This Post Posted: 09 December 2009 at 2:11pm
I made this change, but it introduced a problem where if I manually scroll down, then click on any row, the control scrolls all the way to the top.
So, this is not the real fix.
 
--Larry
Back to Top
mdoubson View Drop Down
Senior Member
Senior Member
Avatar

Joined: 17 November 2008
Status: Offline
Points: 1705
Post Options Post Options   Thanks (0) Thanks(0)   Quote mdoubson Quote  Post ReplyReply Direct Link To This Post Posted: 09 December 2009 at 2:18pm

It used little bit different now - please get updated source - https://forum.codejock.com/uploads/DemoVersion/ReportControlMFCUpdated.rar

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.203 seconds.