Radio Control Confirm problem

S

steve4446

I'm using radio buttons to switch between modes (New & Edit) in an Excel
Worksheet. Each of these modes has associated controls and code. When a user
switches between New & Edit, their "in-progress" changes will be lost. I want
to ask them to confirm that they want to do this and lose any unsaved
information.

I've been using a VB Yes/No box with the message ("Do you want to switch to
New/Edit and lose unsaved information?"). The problem is when the user
selects "No".

Here's a typical problem workflow. User is working in "New" mode. He clicks
the "Edit" radio button. The radio button is selected and on click() the
confirmation box pops up. User doesn't want to lose unsaved information, so
clicks no. Radio button reverts to "New" mode.

However, in reverting back to "New" mode, Excel now pops up the opposite
confirmation asking if the user wants to enter new mode, etc, etc. Clicking
"no" everytime leads to an endless loop.

Help?
 
I

Incidental

Hi Steve4446

Just in case... Are you exiting the sub after the user selects No???
i.e.

If Result = vbNo Then

Exit Sub

end if
 

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

Top