![]() |
Need custom color palette for form object on worksheet
Hi, I have a worksheet with a few embedded form comboboxes. I also
have installed a custom color palette and would like to set the initial value of these boxes to one of the custom colors. The Change event of each box, then sets the background color to white. What is the best way to set the background color so that once it is changed to white it will not rest to the custom color when the workbook is re-opened? Thanks! |
Need custom color palette for form object on worksheet
Maybe there's a better way but you can add some code to a close event for the
form that stores the codes for the colors per object (ex. Record in table_CboxColors: ObjName = cbox_Customer ObjForecolor = 255). Then you can add an on open event that loads these colors in. You may have to cycle through the objects on the form (for each obj in me.objects kind of a thing) and see what it's name is. If the name matches the object name in the table then apply the associated forecolor. I say that only because I don't know how to use a string variable with a me.xxx statement. Can you? Anyway, I hope that helps. " wrote: Hi, I have a worksheet with a few embedded form comboboxes. I also have installed a custom color palette and would like to set the initial value of these boxes to one of the custom colors. The Change event of each box, then sets the background color to white. What is the best way to set the background color so that once it is changed to white it will not rest to the custom color when the workbook is re-opened? Thanks! |
All times are GMT +1. The time now is 03:02 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com