Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Good evening,
When the 'Please Enter Vendor Name" prompt appears it gives you 'Ok' and 'Cancel'. If you press okay it cycles through the way it should but when you press cancel, it automatically goes to the first blank row and asks you if this is correct. I'd like it to be if you press cancel, that's it, No more! Dim sUsername As String Dim sPrompt As String sPrompt = "Please enter vendor name" sUsername = InputBox(sPrompt, sTitle, sDefault) Sheets("list").Select Range("d4").Select Cells.Find(What:=sUsername, After:=ActiveCell, LookIn:=xlFormulas, LookAt _ :=xlPart, SearchOrder:=xlByColumns, SearchDirection:=xlNext, MatchCase:= _ False, SearchFormat:=False).Select Answer = MsgBox("Is this the contract/vendor you would like to delete?", vbYesNo + vbInformation, "Please Confirm") If Answer = vbYes Then Selection.EntireRow.Delete Exit Sub |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Prompt user to select a printer using a checkbox within a user | Excel Programming | |||
Cancel 'Password' prompt during VBA | Excel Programming | |||
VBScript to prompt Save on Cancel click | Excel Programming | |||
How to CANCEL file SAVE PROMPT when MACRO is running? | Excel Discussion (Misc queries) | |||
Cancel Macro is user selects 'cancel' at save menu | Excel Programming |