Close Window   
Free Ebook
Get Your Free Excel
Our Top 15 Excel Tutorials
Instant Access!
Subscribe for Free Excel tips & more!

Format Combo Box

Forum Register
Search Excel Forum Posts, Tutorials, Macros, Tips, and More

Hi All. I have a combo box I'm using to select a time of day within a vb form using Excel 2007.

The row source format is "13:30", and when dropping down the combobox, everything looks fine.
and so on....

However, once I select the time, it converts the value to decimal....

How can I format the combo box to HH:MM in vba?

Many thanks!!

View Answers     

Similar Excel Tutorials

Format Cells as Time in Excel
This free Excel macro formats a selection of cells in the Time format in Excel. This Time number format means that ...
Format Cells in The Number (Numerical) Number Format in Excel
This free Excel macro formats selected cells in the Number or Numerical number format in Excel. This means that th ...
Format Cells in The Short Date Number Format in Excel
This free Excel macro applies the Short Date number format to a selection of cells in Excel. This number format di ...
Format Cells in The Long Date Number Format in Excel
This free Excel macro formats a selection of cells in the Long Date number format in Excel. The Long Date number f ...

Helpful Excel Macros

Format Cells as Time in Excel
- This free Excel macro formats a selection of cells in the Time format in Excel. This Time number format means that inst
Format Cells in The Number (Numerical) Number Format in Excel
- This free Excel macro formats selected cells in the Number or Numerical number format in Excel. This means that the cel
Format Cells as an Accounting Number in Excel Number Formatting
- This free Excel macro formats a selected cell as an Accounting number. This means that the accounting number format is
Format Cells as a Scientific Number in Excel Number Formatting
- This free Excel macro formats selected cells in the Scientific number format in Excel. This means the cell will be put
Format Cells in The Short Date Number Format in Excel
- This free Excel macro applies the Short Date number format to a selection of cells in Excel. This number format display

Similar Topics

how do i show a blank on form combo box every time user open the workbook?

If it is a Forms ComboBox (i.e., you used the Forms toolbar to make the ComboBox), right-click on the ComboBox, and select Format Control. On the Control tab, look for the Input range blank, and enter your list name.

i had linked the form to few cells stated yes no na. but i want the user to open with a fresh new copy with blank on the combo box

I am a novice to VB. I have a UserForm with a combobox. The combo box Control Source is a range such as A1:A30. It has a list of times. When I select the time in the combobox is displays as the Time value. How can I have it display in a more readable format such as HH:MM?

Your help is much appreciated!

Hi There,
I have a form which has two combo box's, I want the second combo box to be enabled if the value in combo box 1 meets a certain criteria.
For example
if combo box 1 = 1 then
combo box 2 . enable
end if

I am using an after update function on combo box 1 to trigger the event.

Thanks in advance

I first put in a format combo box which has 10%, 20%, 30% etc. When selected (it works fine) it has a formula to change the percent to 90%, 80%, 70% in the other cell (=1-(Criticial_Requirements_Weighting/10)). The only problem was the font on the selection in the combo box was very small and did not look good. I read that I could not change the appearance of this combo box. I changed it to an active x combo box, but now when I select an item in the drop down, it looks like 10%, 20%, 30% but when i click and view the selection in the cell it is displaying as 0.1, 0.2 or 0.3. I added the following


Private Sub ComboBox1_Change() 
    ComboBox1.Text = Format(ComboBox1.Value, "0 %") 
End Sub 

If you like these VB formatting tags please consider sponsoring me in support of injured Royal Marines

Now my formula does not work and it is still displaying 0.1. Is there a way to change the look of the cell and drop down selection using the combo box and not the active X combo box? I have been trying everything for a week now, but nothing is working, thanking you in advance.


I have a combo box that filters onto to another combo box; i.e. the first combo box has the following list linked from a table: 1, 2, 3, 4, 4.1, 5.1, 5.2, 5.3. These are displayed fine in the first combo box, but when you click on the second combo box it rounds the 4.1 to 4 and doesn't return anything for 5.1, 5.2 or 5.3. It returns the whole numbers fine. I have set the data type as number and the field size to double. I feel it is something the in the form properties but i am stuck.

Please help.

Dear Excel Expert

My combo box has a ListFillRange (Record Source) made up of Dates. When I select a date from the combo Box it converts it to a number 39325. I want the date to appear 01/09/2007 instead of 39325 but I coulnd't locat a data type property in the combo box.

Thanks so much.

I appreciate your help.


I am trying to create an ActiveX Combo box which displays a list of dates formatted in the style "14-Mar-98". However, once you select a date from the combo box, what is displayed within the combo box is a text string (e.g. 37864).

Does anyone know how to format an ActiveX Combo box so that whatever you choose is displayed in a date form?


I have a list of months in a range and these months are in the the following format 'mmmm yy'. They are entered into the cells as 1/1/09, 1/2/09, etc.

When this range is used as a row source in a combo box the month is shown numerically when a month is selected. E.g. the user selects January 09, but the combo box then shows the selection as 3945.

Is there a way of getting the combo box to show the format as specified in the range to which it points?


Hi! I have searched allover the web and can't seem to find a solution so I'd appreciate any guidance you can give me!

I have a series of cascading combo boxes in which the selection criteria for each successive combo box is limited based on what has been selected in previous combo boxes. I used EKIM's method found on this page

In doing this though, I seem to have encountered an instance where Office 2007 does not update the cell link. The simplified scenario I'm working with is this:

3 combo boxes

combo box 1: options 1 and 2

combo box 2 has a dynamic range which re-sizes based on what you select in Combo box 1.

if combo box 1 = 1; combo box 2 has options a, b

if you select 1= 2; combo box 2 has c

combo box 3 has a dynamic range which re-sizes based on what you select in Combo box 2.
if combo box 2 = a; combo box 3 has options: a1, a2, and a3
if combo box 2 = b; combo box 3 has options b1, b2
if combo box 2 = c; combo box 3 has options c1

it all works from the start. BUT if you select:
combo box 1 = 1
combo box 2 = b
combo box 3 = b3

THEN change to

combo box 1=2
combo box 2=c

there is no options for combo box 3, and any linked references are all #REF
The reason is that the cell link for combo box 2 doesn't change and remains 2. WHY?? What can I do to make it shift back to 1 (which it should do automatically because c is the only option and thus necessarily the 1st in the list)

Hi, I was looking for some help on a excel worksheet which I have used the form control combo box on the worksheet and the combo boxes are populated by lists in hidden columns.

I have two combo boxes on the worksheet. From Combo Box 1 the user can select A, B or C. In combo box 2 the user can select between 5% through 95% (in 5% increments).

I would like combo box 2 to be hidden and only be visible upon selecting "C" in combo box 1. Is this possible? Any help would be appreciated.

Thank you!


I have created 3 combo boxes on a user form. I have set up dynamic ranges in excel that change depending on the user's selection ie - choose an option for combo box 1, the ItemList for combo box 2 will then update, and so on. I am using row source in each combo box to reference the relevant dynamic range.

I am finding that there can be a time delay in ItemList updating for subsequent combo boxes and if you click too quickly into the next combo box, you actually see the items relevant to the original selection in the previous combo box.

Have I done something wrong? Is this a known problem? More importantly, is there a way to make this work properly?


Hi, all

Im having trouble with a combo box with a range of dates as the drop down list.

The Named Range it is connected to is as below


But when i run the user form the Combobox drop down box show as below


When i Select one the combo box does then Show the list in date format

How can i make the dropdown list show in date format also below is the code i currently have for the combobox

Private Sub ComboBox4_DropButt*******()
ComboBox4.List = Application.WorksheetFunction.Transpose(ThisWorkbook.Names("Date").RefersToRange)
ComboBox4.Value = Format(ComboBox4.Value, "dd/mm/yy")
End Sub

Can anyone Help



I have a combo box with a list of options from which the user can choose.
The problem is that I can't seem to change the font of the text in the combo
box. I want to make the text bigger or perhaps bold it. Right clicking on
the combo box only allows me to assign a macro or enter the format control.
There does not seem to be a way to change the format of the font in the combo
box. Any help greatly appreciated.

Hi folks,

On a worksheet I have a combobox which is linked to a cell. The combo box is filled with values in a range (values 1 to 47 in number format in the range). I use the linked cell as the basis of a whole bunch of Vlookup formulas. For instance, if you select #5 in the combobox, the value of cell N13 becomes 5, and then the vlookup formulas use N13 to fill other cells with appropriate data.

The problem I have is that when ever I select a new item in the combo box the linked cell automatically converts the number into 'number stored as text'. The vlookup formulas all become #N/A unless I click on the error message in the linked cell and 'convert to number'. Once I do that everything works fine. Is there a way make sure the linked cell does not automatically convert to 'number stored as text'?

Many thanks!


I created a Combo Box from the Forms toolbar. The Combo Box's input range is a list of dates contained on another worksheet in the same workbook. The Combo Box's Cell Link is on the same worksheet as the Combo Box.

When I select a date form the Combo Box the linked cell also shows the date with the correct day and month, but the year is always 1900; no matter what years I change the master list to.

The format is correct in the linked cell, but the year always coomes up as 1900 no matter what I do.

I tried the 1904 date system, but that made it worse.

I can accomplish exactly what I am aiming for with cell Data Validation, but would like to use a Combo Box if possible.

Any suggestions are greatly appreciated. Thanks in advance.

Good morning fellow Access devs,

On my Mainform is a Subform with two combo boxes: Combo A and Combo B. Combo B is dependant on the selection made in Combo A.

My sql string as follows.

SELECT Table.Field1 AS Expr1, Table.Field2 AS Expr2
FROM Table
WHERE (((Table.Field1)=[Forms]![MainForm]![SubForm].[Form]![ComboBox A]))
ORDER BY Table.Field1;

When I run this from the query (i.e not from the main form), I enter the correct paramenters and the query returns the correct information.

When I run this from the mainform, I select the value in Combo A (which runs a requery for Combo B). Combo B however, is not populating as expected.

What could be the problem?

I've tried: WHERE (((Table.Field1)=[Forms]![SubForm]![ComboBox A])). This works on another project, but i can't see why it wouldn't on this one.

Any suggestions?

I've got a userform with mutliple combo boxes

Each of the combo boxes selects from a separate named range

Is it possible to have the options in combo box 2 change depending on the option selected in combo box 1?


combo box 1 choices, 1,2,3,4,5 (named range 1)
combo box 2..........
if combo box is "1" then select from (named range 2) a,b,c,d,
if combo box is "2" then select from (named range 3) X,y,z

then if combo box 2 is X then select from (named range 4) P, Q,R)

I've used combo boxes in my form but there may be an easier way. I am willing to learn.

Thanks in advance.


I have a sheet which contains two combo boxes. Combo box 1 contains organisation type and combo box 2 contains a list of regions.

I want the option from the combo box 1 to determine the options shown in the combo box 2

In particular, if they select a certain org. type I want the combo box 2 to be blanked out, but if they select any of the other org types I want the options in combo box 2 to be shown.

Thanks in advanced if you can help.

Hi folks..

I've a form with 2 combox boxes on it. I can Filter one combobox based on another combobox selection (taken from but,

The first combo box shows me the list of Form classes in our school and based on this, the second combo box shows a list of students who are in this class. All works fine apart from one small problem. The names in the second combo box don't apear in alphabetical order.

Is there a way of making the combo box display the names in alphabetical order. I've tried setting the combo box row source SQL query to sort in order of ascending but nothing happens.

Running the sample file from the URL above shows the same problem.




All of the combo boxes in my user form suddenly stopped dropping down to show their choices when I click the drop button. The combo boxes worked fine until now. The combo boxes still populate because when I put the focus in any of them and press the down arrow key, I can scroll through the options. I just can't see all of the choices at once. I would appreciate any advice you may have on how to fix this. Thanks.


Following this:

To have one combo box drive the list of possible values in another combobox.

I'm having trouble with one portion. My 2nd combo box (the driven) needs to be refreshed each time my 1st combobox is changed. The driven combo box resides in a subform of my form that contains the first combo box (companyID).

The name of my subform is ReportLine SubForm - Other. The name of my driven combo box is simply modelID.

What would be the syntax for updating the 2nd combobox?


Private Sub CompanyID_AfterUpdate()
ReportLine SubForm - Other.ModelID.Requery
End Sub

I get an error on 2nd line

Hi guys, I will appreciate your assistance on this:

I am trying to populate combo box 2 based on the input in combo box 1. Given the data set below:

Source 1 Source 2
AA 2
AA 2
AA 4
BB 10
BB 15
BB 20
CC 3
CC 6
CC 9

I want the results to show as follows:

Combo Box1 Combo Box 2 Combo Box1 Combo Box 2 Combo Box1 Combo Box 2
AA 2 BB 10 CC 3
4 15 6
20 9

If "AA" is selected in Combo box1, I will like Combo box 2 to display ("2" and "4"); If "BB" is selected in Combo box1, I will like Combo box 2 to display ("10", "15" and "20");

I have tried using this function: Me.Bn.Value = Application.VLookup(Me.Phs.Value, Worksheets("CycTA").Range("V5:W" & LastRow), 2, False) but it is not working.
In my code: Combo box 1 and 2 are named "Phs" and "Bn" respectively.

Pls find the attached file.

Thank you!

Hi all, again not having a good time with vba, its been a while...

Firstly I want the combo box list to be "POSITIONAL COMBO LISTS!$C$2:$C$35"

I don't want any blanks to come though, but i just can't get rid of them!!!

and then i need the combo box value selected to determine whats in my frame, pulling in a chart/worksheet.

COMBO BOX name= "ComboBoxPosTraining"
FRAME name= "frmeposschedules"

example of what i mean, IF combobox value = "WINGER ATTACK", then "Chart50" to show in the frame...

Please say someone can help...

This is only my second time here so be nice!!
I have a two questions regarding combo boxes on an Excel spreadsheet.

1) Using the form combo box can the font size be changed?
2) Using an active X combo box, how can I get it to work and how do you add anything to it. I add one go in to properties but I can't click on the box so it works??? confused!! ?


im having problems listing items in a combo box and having them show up when I actually run the program. I have 7 items i want to list in the combo box for the user to select from. whats the format of the vb code? I'm a beginner. any help appreciated