Excel VBA User Form - button problem

  • Thread starter Thread starter weakissues
  • Start date Start date
W

weakissues

How can I create a command button that when pressed adds text or a valu
into a worksheet cell, but skips full cells until it gets to the nex
empty one to put it in. I am creating an EPOS system and a listbox o
the form will display a specific cell range, but i want the button t
add say SOUP if soup is clicked, but then is MUSHROOMS is clicked, i
adds it to the next cell down (skipping the cell which will have SOU
in it). Please help, this has been driving me crazy all week, i can
think how to do it at all. Thanks a lot. Cu
 
Private Sub CommandButton1_Click()
do while activeCell.Value <> ""
ActiveCell.Offset(1,0).Select
Loop
ActiveCell.Value = me.Listbox1.Value
End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top