ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   YES/NO Button - Tied to Macro Functions (https://www.excelbanter.com/excel-programming/360712-yes-no-button-tied-macro-functions.html)

TEAM[_15_]

YES/NO Button - Tied to Macro Functions
 

I need some help tieing yes/no option buttons to macros for several
different functions.

I have a menu page with five separate yes/no questions and a second
sheet that has a variety of inputs in columns A, B and C.

The user will make yes or no selections on the menu page and click a
command button ("Submit"). The command button will be tied to all
macro functions that follow. For example, if the user selects "no" for
question one and "yes" for the other four questions, then the macro
will...

1. Delete contents of sheet 2 A4
2. Delete contents of sheet 2 B7
3. Delete contents of sheet 2 B11
4. Prompt user for a "name" input, which will be used to find and
replace the word "person" in all cells on sheet 2.
5. Create a new file out of sheet 2 and save it as "name"
6. Close the original file without saving changes.


If the user selects "no" for questions one and two, then

--Perform the same steps as one through three above
--Delete cells A2 and C5 on sheet 2
--Resume with steps four through six from above


--
TEAM
------------------------------------------------------------------------
TEAM's Profile: http://www.excelforum.com/member.php...o&userid=22810
View this thread: http://www.excelforum.com/showthread...hreadid=539385



All times are GMT +1. The time now is 10:53 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com