Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
BeforeUpdate and Cancel
Thanks for reading my question,
I have a combo box that, upon changing the value, I wish to ask the user if they are sure they want to make the change as there are consequences. How can I do this? I have tried if statements on the _Change event of the combo box, but can't get that to work, and can't get the combo box to look at the BeforeUpdate () line (as is seen below). I have also tried the solution posted by Todd on May 7, and couldn't get it to work. Thanks in advance, Brad Private Sub ComboBox2_BeforeUpdate(ByVal Cancel As MSForms.ReturnBoolean) Dim Answer As Variant Answer = MsgBox("Changing this value will delete the current list of feeds, and numbers of birds per feed stage. This will affect the Feed Stage Combo boxes on this sheet. Do you wish to continue?", 36) If Answer = vbNo Then Cancel = True Else GetProductNames End If End Sub |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Workbook_BeforeClose(Cancel As Boolean) - Cancel won't work | Setting up and Configuration of Excel | |||
cancel save | Excel Discussion (Misc queries) | |||
Input Box - CANCEL | Excel Worksheet Functions | |||
How can I expose the TextBox BeforeUpdate event to my user class? | Excel Discussion (Misc queries) | |||
BeforeUpdate event for Combo box | Excel Programming |