Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #1  
Old 06-15-2017, 07:47 AM
JellehFish JellehFish is offline Run 1 of 2 Macros Depending on Y/N Response to Message Box Windows 7 64bit Run 1 of 2 Macros Depending on Y/N Response to Message Box Office 2010 64bit
Novice
Run 1 of 2 Macros Depending on Y/N Response to Message Box
 
Join Date: Jun 2017
Posts: 1
JellehFish is on a distinguished road
Default Run 1 of 2 Macros Depending on Y/N Response to Message Box

Hi,

I'm trying to write a macro that uses the MsgBox function to select which one of two macros should be run.

The actual macros themselves run fine, but trying to tie them together is proving difficult. I looked around online and couldn't find any clues, so this particular solution may not even be possible.

I have this macro which functions as I'd expect it to:

Sub MACRO()
If MsgBox("Run Macro A?", vbYesNo) = vbYes Then Macro A
End Sub



I want to add something to the effect of:

= vbNo Then Macro B

If I substitute the vbYes line for this vbNo line it runs as expected but can't get it to do both without prompting two message boxes.

It's so simple that I'm hoping there is an easy answer and I don't have to go about a completely different solution.

Any help is greatly appreciated.
Reply With Quote
 



Similar Threads
Thread Thread Starter Forum Replies Last Post
Help: Very low response-rate! Jeff10 Office 6 12-17-2013 10:44 AM
Reply All in auto response Quackymacduck Outlook 0 10-12-2011 11:50 AM
Failing calendar response lucura Outlook 0 03-24-2011 01:01 AM
Run 1 of 2 Macros Depending on Y/N Response to Message Box appointments deleted from inbox upon response Roscoe Outlook 1 03-03-2010 12:15 PM
Unexpected Server Response GreenAccord Project 0 01-31-2006 12:52 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 12:42 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft