Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Report Control
  New Posts New Posts RSS Feed - CXTPReportControl problems with many columns
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

CXTPReportControl problems with many columns

 Post Reply Post Reply
Author
Message
Fredrik View Drop Down
Senior Member
Senior Member


Joined: 22 June 2005
Status: Offline
Points: 226
Post Options Post Options   Thanks (0) Thanks(0)   Quote Fredrik Quote  Post ReplyReply Direct Link To This Post Topic: CXTPReportControl problems with many columns
    Posted: 04 November 2009 at 6:21pm
I am testing the report control with a few thousand columns in virtual mode and noticed a few problems:

1) If you drag the horizontal thumb to the right the scrolling will snap back to first column when you pass column 700 or so. (Using GetScrollInfo for the cases SB_THUMBTRACK SB_THUMBPOSITION in CXTPReportControl::OnHScroll2 instead of nPos solves the problem.)

2) In virtual mode: If you pass pos == NULL in a call to GetNextSelectedRow(pos) it will return a pointer to m_pVirtualRow instead of NULL - did not expect that...

3) If you have a few thousand columns and your mouse happen to pass over some of the column headers the application will become unresponsive for some time (5-10 seconds).

Actually, what I want is an EXCEL like spreadsheet and perhaps CXTPReportControl is not designed for that - if this is the case, does anyone have a suggestion for an alternative control?

Using v. 13.2.1

By the way, isn't there a missing 'l' in the name GetFulColScrollInfo() ;-)?

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: 05 November 2009 at 8:05pm

Excel spec: Rows <= 64K, Columns <= 256

Back to Top
Fredrik View Drop Down
Senior Member
Senior Member


Joined: 22 June 2005
Status: Offline
Points: 226
Post Options Post Options   Thanks (0) Thanks(0)   Quote Fredrik Quote  Post ReplyReply Direct Link To This Post Posted: 06 November 2009 at 1:24pm
Originally posted by mdoubson mdoubson wrote:

Excel spec: Rows <= 64K, Columns <= 256



Not sure if this was an answer or general information but I don't see any value in your post?

For your information, Excel 2007 supports 16384 columns and over a million rows.
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: 06 November 2009 at 1:27pm
It was general info based on Excel2003 and prev versions
Back to Top
Fredrik View Drop Down
Senior Member
Senior Member


Joined: 22 June 2005
Status: Offline
Points: 226
Post Options Post Options   Thanks (0) Thanks(0)   Quote Fredrik Quote  Post ReplyReply Direct Link To This Post Posted: 11 January 2010 at 3:48pm
By the way, will the scrolling bug/etc be fixed in next version of the Toolkit?

When is next version expected?
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: 11 January 2010 at 3:52pm
Back to Top
Fredrik View Drop Down
Senior Member
Senior Member


Joined: 22 June 2005
Status: Offline
Points: 226
Post Options Post Options   Thanks (0) Thanks(0)   Quote Fredrik Quote  Post ReplyReply Direct Link To This Post Posted: 11 January 2010 at 4:06pm
Thanks for the quick reply. Is there a MFC version I can test instead of the active x control?
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: 11 January 2010 at 4:10pm
Sure - https://forum.codejock.com/uploads/DemoVersion/ReportControlMFCUpdated.rar but you need to comment line

#include "XTPReportRecordTrackMod.h"

and body of BOOL CXTPReportControl::ExecuteSnapAction(int nTimeMarker, BOOL bLeft)
and BOOL CXTPReportControl::ExecuteSnap2Clip(BOOL bLeft) - leave only return FALSE in the end.
Back to Top
Fredrik View Drop Down
Senior Member
Senior Member


Joined: 22 June 2005
Status: Offline
Points: 226
Post Options Post Options   Thanks (0) Thanks(0)   Quote Fredrik Quote  Post ReplyReply Direct Link To This Post Posted: 14 January 2010 at 8:26am
Thanks Mark,

I tested creating a spreadsheet with 10 000 columns and 100 rows.

My report control no longer "hangs" when moving the mouse over the column headers, but is still rather slow when scrolling and selecting rows. Selecting a row when you have scrolled to the far right of the spreadsheet takes a few seconds on my computer.

Horizontal scrolling still doesn't work. I changed XTPReportControl.cpp, line 4820:

   nCurPos = nPos;

to

   SCROLLINFO si;
   ZeroMemory(&si, sizeof(SCROLLINFO));
   si.cbSize = sizeof(SCROLLINFO);
   si.fMask = SIF_TRACKPOS;

   if (!GetScrollInfo(SB_HORZ, &si))
      return;
   nCurPos = si.nTrackPos;

to make it work for me.

By the way, if you lock/freeze the first column and use the xtpReportFreezeColsDividerShade style it doesn't look really nice if you select a row and scroll horizontally:


     
Back to Top
Fredrik View Drop Down
Senior Member
Senior Member


Joined: 22 June 2005
Status: Offline
Points: 226
Post Options Post Options   Thanks (0) Thanks(0)   Quote Fredrik Quote  Post ReplyReply Direct Link To This Post Posted: 22 February 2010 at 5:06am
Hi,

I also tested Toolkit Pro 14.0 Beta and noticed that it was not possible to scroll pass column 600 in a spreadsheet.

Are there no plans to fix it? Of course I can fix it my own sources but I rather not do that after each update.

Windows 10, Visual Studio 20157, Toolkit Pro 18.3.0
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.141 seconds.