View Single Post
  #14   Report Post  
Jan Buckley
 
Posts: n/a
Default

The "next cell" will always be one to the right. Can you write the code for
that? You guys sure are patient with us beginners, and I really appreciate it.

"Dave Peterson" wrote:

If the next cell is down one:

Private Sub ComboBox1_Change()
ActiveCell.Value = Me.ComboBox1.Value
ActiveCell.Offset(1, 0).Activate
End Sub

If to the right one:
Private Sub ComboBox1_Change()
ActiveCell.Value = Me.ComboBox1.Value
ActiveCell.Offset(0, 1).Activate
End Sub

Maybe?????

Jan Buckley wrote:

Dave, this works great, can't tell you how much I've learned during this
little exercise. But is there any way that the user can TAB to the next cell
(after selecting the date from the combo box) rather than having to CLICK
into it? Thanks.

"Jan Buckley" wrote:

JE: That sounds like it would work much better but, not being a programmer, I
don't know how to accomplish it. Can you help?


"JE McGimpsey" wrote:

One way:

For 1 combobox, add this to your worksheet code module (adjust "A1" to
suit):

Private Sub Worksheet_SelectionChange( _
ByVal Target As Range)
ComboBox1.Visible = _
Not (Intersect(Target, Range("A1")) Is Nothing)
End Sub

However, if you've got 500 rows that require comboboxes, I'd consider
rethinking the approach. Perhaps using a single combobox and positioning
it at the appropriate cell whenever one of the cells is selected, then
placing the value of the combobox into the selected cell rather than
hardcoding it.

In article ,
"Jan Buckley" wrote:

I hate to bother you again, but is there a way to "hide" the combo box
until you click or tab into the cell where it resides? I have four columns
(containing up to 500 rows each) on my spreadsheet that will require the
combo boxes and it looks 'ugly' with them all showing. Thanks.


--

Dave Peterson