Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Report Control
  New Posts New Posts RSS Feed - Set the Report Record Height.
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Set the Report Record Height.

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


Joined: 30 November 2007
Status: Offline
Points: 142
Post Options Post Options   Thanks (0) Thanks(0)   Quote markmark Quote  Post ReplyReply Direct Link To This Post Topic: Set the Report Record Height.
    Posted: 19 July 2008 at 4:44am

Hi

 
I have set the row record item to be multline (Item.EditOptions.EditControlStyle = xtpEditStyleMultiline)

 

So long as the row height can take the extra line, CTRL-ENTER will work OK

However if the row height is too small it will not.

I have tried trapping the PreviewKeyDown event so that when KeyCode = 13 And Shift = 2 is true  I can increase the record height.

But there doesn’t seem a way of increasing the record height, other than MeasureRow event.

 

Would there be an auto resize option to increase the record height as the text in the items grows.

 

What I’m trying to achieve, would allow the user to type into the multiline item and the cell to resize its height as the user types

 

Thanks

 

MArk
Product: Xtreme SuitePro (ActiveX) version 13.0.0
Platform: Windows XP (32bit) - SP 2
Language: Visual Basic 6.0
Back to Top
Aaron View Drop Down
Senior Member
Senior Member
Avatar

Joined: 29 January 2008
Status: Offline
Points: 2192
Post Options Post Options   Thanks (0) Thanks(0)   Quote Aaron Quote  Post ReplyReply Direct Link To This Post Posted: 19 July 2008 at 6:15am
Hi,
 
This will auto scroll when adding another line of text:
 
Item.EditOptions.EditControlStyle = xtpEditStyleMultiline or xtpEditStyleAutoVScroll
 
and set:
 
wndReportControl.PaintManager.FixedRowHeight = False
 
Now it will autosize the row to its contents.
 
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....
Back to Top
markmark View Drop Down
Senior Member
Senior Member


Joined: 30 November 2007
Status: Offline
Points: 142
Post Options Post Options   Thanks (0) Thanks(0)   Quote markmark Quote  Post ReplyReply Direct Link To This Post Posted: 19 July 2008 at 7:49am
Thanks again Aaron
 
That does what I wanted.
 
Q
Is there a way to change the row height via a single line of code,
other than using the MeasureRow event?
 
Mark
Product: Xtreme SuitePro (ActiveX) version 13.0.0
Platform: Windows XP (32bit) - SP 2
Language: Visual Basic 6.0
Back to Top
Aaron View Drop Down
Senior Member
Senior Member
Avatar

Joined: 29 January 2008
Status: Offline
Points: 2192
Post Options Post Options   Thanks (0) Thanks(0)   Quote Aaron Quote  Post ReplyReply Direct Link To This Post Posted: 19 July 2008 at 9:09am
Hi,
 
The only way setting a rowheight is using the MeasureRow event, but:
 
If you set wndReportControl.PaintManager.FixedRowHeight = False the row will automatically sized to its contents. You don't need the MeasureRow event if you don't mind that rows have different heights.
 
 
 
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....
Back to Top
markmark View Drop Down
Senior Member
Senior Member


Joined: 30 November 2007
Status: Offline
Points: 142
Post Options Post Options   Thanks (0) Thanks(0)   Quote markmark Quote  Post ReplyReply Direct Link To This Post Posted: 20 July 2008 at 2:18am
Hi
When you  are typing into an Item and type CTRL-ENTER the row doesn't expand to fit the text untill you click out of the item.
 
I was going to trap  CTRL-ENTER and expand the row.
Unless there's another setting?
 
Thanks for your help
 
 
MArk
Product: Xtreme SuitePro (ActiveX) version 13.0.0
Platform: Windows XP (32bit) - SP 2
Language: Visual Basic 6.0
Back to Top
Aaron View Drop Down
Senior Member
Senior Member
Avatar

Joined: 29 January 2008
Status: Offline
Points: 2192
Post Options Post Options   Thanks (0) Thanks(0)   Quote Aaron Quote  Post ReplyReply Direct Link To This Post Posted: 20 July 2008 at 4:34am
Hi,
 
If you type into a textbox it won't autosize either, it will only scroll. Same way as you do now, with reportitem multiline. If I were you, I wouldn't put so much effort in it just to fit the contents into row. Users don't expect that it will resize, just scroll down as they type. I know it's difficult to let go when you have something in mind, but I wouldn't go this far
 
btw, I added this as possible feature to my FIXED BUGS post: have a scrollbar with multiline reportitem. Would be nicer anyway, this way you could set a certain height for every row and still see that the contents is bigger then the rowheight.
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....
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.250 seconds.