![]() |
|
#1
|
||||
|
||||
![]() The basic problem is that you're misusing StrMsg. You define it as being a particular string, with no way to change it, then try to test whether it's something else! Try something based on: Code:
Private Sub ComboBox1_NotInList(NewData As String, Response As Integer) Dim varMsg As Variant ' Prompt user to verify they wish to add new value. varMsg = MsgBox("'" & NewData & "' is not in the list. " & _ "Would you like to add it?", vbOKCancel) If varMsg = vbOK Then MsgBox "OK" Else MsgBox "Cancel" End If End Sub
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
![]() |
rsrasc | Word VBA | 7 | 03-28-2014 12:28 PM |
![]() |
jmsa7 | Excel | 3 | 12-13-2011 01:44 AM |
![]() |
Girlie4 | Excel | 3 | 08-09-2009 08:02 PM |
Need help with this question... | lllDNYlll | Outlook | 0 | 05-04-2006 07:17 AM |
Categories question & replying with attachment question | glitzymama | Outlook | 0 | 03-15-2006 09:32 AM |