CoolBar Height

02-27-2003, 08:17 AM
A bizzare one this.

Ive got a toolbar stuffed into a coolbar, that gets filled with icons depending on what you are looking at. Sometimes I get a lot of icons that go off the page. There is only ONE band.
The toolbar actually wraps the icons onto the next line, but the coolbar does not resize to show the new height. If you test the height of the toolbar you get its old value (before the resize, at least thats what I think it is).

Has any1 managed to figure out a nice way of making the coolbar change size ?

02-28-2003, 02:57 PM
You can control the height by setting the MinHeight property of the relevant Band object.
This property behaves oddly - for horizontal coolrbars it's the height, for vertical coolbars it's the width.

02-28-2003, 04:57 PM
You read my question wrong or I didnt write it correctly :). I can set the height of the band, thats not the problem, when the toolbar is resized, its height value is not updated until the draw has finished. By that time you have exited the resize procedure.

Ive sorted it but what I had to do is have a timer that runs straight after the resize to check the new height.

There is also a bug in the toolbar that makes it not update itself when you add new buttons, so you have to force a resize on that. M$ suggest an API call to do it.

Thats just for any1 else who wanted to know :)

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum