Thread: Listbox Problem
View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.misc,microsoft.public.excel.programming
Bob Phillips[_6_] Bob Phillips[_6_] is offline
external usenet poster
 
Posts: 11,272
Default Listbox Problem

Private Sub CommandButton2_Click()
Worksheets("Messages").Range("A2").Offset(ListBox1 .ListIndex).Delete
End Sub


--

HTH

RP
(remove nothere from the email address if mailing direct)


"browie" wrote in message
...
I have a list box which I have set up which runs a message bank. I would
like it to have the ability to delete the sected message from the

worksheet.
How can I do this?

userform name is "splash"

listbox1 its rowsource is messagesa2:a1000
and the button i wish to use to delete is commandbutton2

any help with the code would be great

Thanks

Greg