Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
VBA/ActiveX ComboBox autosize bug - Selection of value multiple times shrinks text.
Hi,
I've spent a little time adding some verification code into an embedde excel spreadsheet and one of the things I added were ActiveX Comb boxes linked to cells, and positioned them over the top of the cells Now this is fine until one of the long entries from the list programmatically provide for the Combo boxes is selected. The defaul behaviour of Excel to display this if no value is entered in the nex column, is to show the value over part of the adjoining cell. So I put code in the Combobox_Change() event to size the column to th autosized Combobox width. It all works fine and I'm happy with th results of my labour. Just upset now that I find a bug in the autosiz of the objects. If I select values from the ComboBox multiple times i seems to shrink the text width smaller and smaller even though th objects have their font set to Arial 7. So I was wondering if anyon had developed a fix or even a work around for this bug??? Please help if you can, it will save me from having to scrap a larg chunk of code, Thanks.. Bruce -- Message posted from http://www.ExcelForum.com |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
VBA/ActiveX ComboBox autosize bug - Selection of value multiple times shrinks text.
I don't know if this is relevant, but I've recently noticed shrinking
font in a textbox in one of my apps. It seems that if the textbox is fractionally too small to accommodate the text, the font shrinks to accommodate. I've made no attempted to find out why this happens because it works in my favor! So my suggestion to you is to try increasing the size of the column and/or control a bit larger than the AutoSize size. BTW is the combobox on a worksheet? I've seen a similar bug where the combobox itself doubled in size each time it was dropped down. I used an event to resize it back to normal and I *think* this resulted in the font shrinking instead. However, this bug only occurs when the screen resolution is changed (e.g. via Control Panel, Display, Settings, Screen Resolution) while the workbook is open. -- Arris wrote in message ... Hi, I've spent a little time adding some verification code into an embedded excel spreadsheet and one of the things I added were ActiveX Combo boxes linked to cells, and positioned them over the top of the cells. Now this is fine until one of the long entries from the list I programmatically provide for the Combo boxes is selected. The default behaviour of Excel to display this if no value is entered in the next column, is to show the value over part of the adjoining cell. So I put code in the Combobox_Change() event to size the column to the autosized Combobox width. It all works fine and I'm happy with the results of my labour. Just upset now that I find a bug in the autosize of the objects. If I select values from the ComboBox multiple times it seems to shrink the text width smaller and smaller even though the objects have their font set to Arial 7. So I was wondering if anyone had developed a fix or even a work around for this bug??? Please help if you can, it will save me from having to scrap a large chunk of code, Thanks.. Bruce. --- Message posted from http://www.ExcelForum.com/ |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
ComboBox autosize | Excel Worksheet Functions | |||
ActiveX combobox | Excel Worksheet Functions | |||
ActiveX Combobox and LinkedCell | Excel Worksheet Functions | |||
fill combobox depending on selection from another combobox | Excel Discussion (Misc queries) | |||
How do i populate a text box according to selection in combobox? | Excel Worksheet Functions |