SOLVED: RowHeight |
Post Reply |
Author | |
ElvisM
Senior Member Joined: 12 October 2006 Location: Venezuela Status: Offline Points: 129 |
Post Options
Thanks(0)
Posted: 12 June 2008 at 12:05pm |
Hi friends, maybe this question is too simple...
How can I change by code, the rowheight in the reportcontrol?
Regards,
Elvis
|
|
Product: Xtreme SuitePro (ActiveX) version 17.2
Platform: Windows 10 64bits Language: Visual Basic 2015 |
|
Aaron
Senior Member Joined: 29 January 2008 Status: Offline Points: 2192 |
Post Options
Thanks(0)
|
Hi,
You can not change the RowHeight itself, it will be sized by its contents if you set wndReportControl.PaintManager.FixedRowHeight = false
|
|
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2 Language: Visual Basic 6.0 Zero replies is not an option.... |
|
Baldur
Senior Member Joined: 22 November 2006 Location: Germany Status: Offline Points: 244 |
Post Options
Thanks(0)
|
Yes you can !
MyReport.SetCustomDraw xtpCustomMeasureRow
Than you get for each Row a MeasureRow-Event.
|
|
Aaron
Senior Member Joined: 29 January 2008 Status: Offline Points: 2192 |
Post Options
Thanks(0)
|
Hi,
Thanks for sharing
Will this event be raised everytime the RC contents changes? Just like the BeforeDrawRow event? If so, I will have my concerns about using this. It's taking alot of CPU time already
|
|
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2 Language: Visual Basic 6.0 Zero replies is not an option.... |
|
Baldur
Senior Member Joined: 22 November 2006 Location: Germany Status: Offline Points: 244 |
Post Options
Thanks(0)
|
Yes, This event happens every time the report must be redrawn (e.g. CursorMove, Mouseclick) !
I must use this, because i use WordBreak in the Caption. If i not use this event each row becomes to heigh. I need only 17 pixels, the default becomes 22.
But the lost time doesn't matter !
MeasureRow is fired one per row, BeforDrawRow is fired 2 times for each Item !
I use also CustomDraw !
So i get many events but this works very fast for me.
In an other test before i use the virtual mode with ADO-Recordset.
THIS was the main performance break !!!
Each access to the Recordset.AbsolutePosition makes problems.
To understand:
Each DrawBeforeRow (for each item), i set the AbsolutePosition.
Each DrawItem set the AbsolutePosition.
The reason was, that DrawBeforeRow and DrawItem are not fired consistently (eg. first visible row, than last visible row, than each row and than the items).
The setting of AbsolutePosition and the question of that property takes the same time !!!
So now i don't use virtual mode and fill the entire recordset to the report.
I have done a measurement:
Filling up 10.000 lines with 20 columns in 3 Seconds without access the AbsolutePosition (count by myself).
But with access of AbsolutePosition i need about 70 seconds !!!
I don't find anything in the internet why this property takes a long time.
It's also independent if the recordset is connected with ClientCursor or build by my own.
|
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |