Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #1  
Old 12-24-2017, 05:50 AM
Larry_1 Larry_1 is offline How to trigger a macro on cell *selection* Windows 10 How to trigger a macro on cell *selection* Office 2010 64bit
Novice
How to trigger a macro on cell *selection*
 
Join Date: Dec 2017
Posts: 9
Larry_1 is on a distinguished road
Default How to trigger a macro on cell *selection*

I am slowly learning VBA.



I have an Excel spreadsheet and between 25 and 100 MS Word documents in the same hard drive folder. The spreadsheet uses 4 sheets. The first sheet, “Available Documents,” has a table with 2 columns:

Document number (for example, “Gardening-0017” – The associated Word document uses the “document number” as the file name.)


Document title (for example, “pruning roses”)

All of the sheet’s cells are protected from edits, and selections are limited to the cells in the document number column. When the user selects a cell in that column, I want to open the associated Word file and then return when the user finishes reviewing that file. I have created a Word template with a command button that minimizes and then closes the Word file, so that should return control to the Excel table. But how to call the document? I could create a command button for each cell in the column, but that seems heavy.

What commands or functions could I use to trigger a macro based on selecting a cell from the document number column (the cells are protected against changes) and call an external document?

And how do I prevent calls based on a multi-cell selection?

I would sincerely appreciate any suggestions that you can offer.

Very respectfully,
Larry





Reply With Quote
 



Similar Threads
Thread Thread Starter Forum Replies Last Post
Limit min and max number to a cell based on country selection hussainshaikh1 Excel 1 02-02-2017 07:06 AM
How do I trigger a macro from a document? brucemc777 Word VBA 4 01-25-2016 01:42 AM
How to trigger a macro on cell *selection* Selection from cell with list contents autopopulates contents of another cell markharper80 Excel 3 02-16-2015 04:18 PM
Hyperlink in cell to trigger pop up text box Carpie Excel Programming 0 08-13-2013 10:33 AM
How to trigger a macro on cell *selection* ms office excel 2007 cell selection issues pavamaklava Excel 1 05-12-2010 10:47 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 09:05 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