LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #2   Report Post  
Posted to microsoft.public.excel.misc
Dave Peterson
 
Posts: n/a
Default Combo Box - format output as time

How about removing that link to the range and just add the values to the
combobox.

dim myCell as range
dim myRng as range

with worksheets("Sheet1")
set myrng = .range("a1:A10")
end with

with me.combobox1
for each mycell in myrng.cells
.additem mycell.text
'or
'.additem format(mycell.value, "hh:mm AMPM")
next mycell
end with



Robert Mark Bram wrote:

Hi All,

I created a combo box that is linked to a set of cells that contain
numbers but for which I have selected to format as time i.e. the cells
look like this:

12:00 AM
12:30 AM
1:00 AM
1:30 AM
2:00 AM
2:30 AM

My problem is that when I select a value with the combo box, it
displays them as the number, not as a formatted time and I cannot see
which property to edit on the combo box to have the output formatted as
time.

Any help would be most appreciated!

Rob
:)


--

Dave Peterson
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Adding Time Format Sloth Excel Discussion (Misc queries) 0 November 1st 05 10:46 PM
Converting from time format to decimal and figuring the difference Steve Williams Excel Discussion (Misc queries) 1 July 30th 05 10:10 PM
Adding time damezumari Excel Discussion (Misc queries) 2 June 20th 05 08:35 PM
Convert decimal hour into time format? ramdalen Excel Discussion (Misc queries) 2 June 20th 05 06:21 PM
convert number to time format? JLHORMAN Excel Discussion (Misc queries) 1 May 26th 05 06:38 PM


All times are GMT +1. The time now is 08:53 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"