Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Report Control
  New Posts New Posts RSS Feed - [SOLVED] Identify the row that already has data?
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

[SOLVED] Identify the row that already has data?

 Post Reply Post Reply
Author
Message
Makarand View Drop Down
Senior Member
Senior Member
Avatar

Joined: 27 February 2007
Location: India
Status: Offline
Points: 140
Post Options Post Options   Thanks (0) Thanks(0)   Quote Makarand Quote  Post ReplyReply Direct Link To This Post Topic: [SOLVED] Identify the row that already has data?
    Posted: 14 April 2011 at 9:40am
Hello CJ Team,

I am implementing CJ Report control in our application, for that I am referring "VirtualList" sample. In that sample application method GetItemMetrics(..) get the data for each column and row and always get called to paint the cell.

I included GetItemMetrics(..) method it is working fine with the small amount of data but in case of large data it is getting slow due to calling GetItemMetrics(..) for each row even I activate the window.

In simple way, once I set the value for "pItemMetrics->strText" for 1 to 50 rows (those are visible) I don't want set it each and every time even I activate the window. What is the way where I can ensure that the data has already been loaded for the respective row in function GetItemMetrics(..) ?

Thanks,
-Mak  
-Mak
Back to Top
ABuenger View Drop Down
Newbie
Newbie
Avatar

Joined: 02 February 2006
Status: Offline
Points: 1075
Post Options Post Options   Thanks (0) Thanks(0)   Quote ABuenger Quote  Post ReplyReply Direct Link To This Post Posted: 14 April 2011 at 10:11am
GetItemMetrics() is called everytime the report control is being painted. In virtual mode the report control doesn't hold or cache any data. GetItemMetrics() is also only called for visible rows.

If the window is deactivated the report control loses the focus, so it needs to be redrawn. Same if the window becomes actived again.


Andre

Codejock support
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.125 seconds.