Print Page | Close Window

Report Control Scroll Problem

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Toolkit Pro
Forum Description: Topics Related to Codejock Toolkit Pro
URL: http://forum.codejock.com/forum_posts.asp?TID=1643
Printed Date: 23 November 2024 at 6:22am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Report Control Scroll Problem
Posted By: brianh
Subject: Report Control Scroll Problem
Date Posted: 10 January 2005 at 3:50am

Hi, if you turn off automatic column sizing (so it doesn't automatically resize columns to fit window) then resize window until the horizontal scroll bar appears you can then drag the scrollbar "thumb" and you can click on the scrollbar arrows to scroll the window, but if you click on the scroll bar itself nothing happens!

This behaviour can been seen in the report control sample program too, is this a bug, can it be fixed?

Thanks.




Replies:
Posted By: Flamer
Date Posted: 22 January 2005 at 6:22am

I notice the same 'bug'. The vertical scrollbar works perfectly!!!

Can this be solved in the next release??? ...Would be great!!!!

 



Posted By: brianh
Date Posted: 24 January 2005 at 3:01am

I reported this as a bug and was told it will be fixed in the next release and given the code below to fix the problem in the mean time:

Yes, it was bug,, we fixed it already.

void CXTPReportControl::OnHScroll(UINT nSBCode, UINT nPos, CScrollBar* pScrollBar) {

if (pScrollBar != NULL)

{

CWnd::OnHScroll(nSBCode, nPos, pScrollBar);

return;

}

int nCurPos = m_nLeftOffset;

// decide what to do for each diffrent scroll event

switch(nSBCode)

{

case SB_TOP: nCurPos = 0; break;

case SB_BOTTOM: nCurPos = GetScrollLimit(SB_HORZ); break;

case SB_LINEUP: nCurPos = max(nCurPos - 1, 0); break;

case SB_LINEDOWN: nCurPos = min(nCurPos + 1, GetScrollLimit(SB_HORZ)); break;

case SB_PAGEUP: nCurPos = max(nCurPos - m_rcReportArea.Width(), 0); break;

case SB_PAGEDOWN: nCurPos = min(nCurPos + m_rcReportArea.Width(), GetScrollLimit(SB_HORZ)); break;

case SB_THUMBTRACK:

case SB_THUMBPOSITION: nCurPos = nPos; break;

}

SetLeftOffset(nCurPos);

CWnd::OnHScroll(nSBCode, nPos, pScrollBar); }

You can replace this member and rebuild dll/lib



Posted By: Flamer
Date Posted: 24 January 2005 at 5:31am

Ok, thx for the feedback!

 




Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net