Solved

Calling the workbook_open sub

Posted on 2013-11-04
3
313 Views
Last Modified: 2013-11-04
How do call the workbook_open sub from one of the worksheet modules or from a new module?
0
Comment
Question by:Saqib Husain, Syed
3 Comments
 
LVL 81

Accepted Solution

by:
zorvek (Kevin Jones) earned 400 total points
ID: 39621147
First, change it to a Public sub. Then call it:

    ThisWorkbook.Workbook_Open

Kevin
0
 
LVL 85

Assisted Solution

by:Rory Archibald
Rory Archibald earned 100 total points
ID: 39621168
Or use:
   Application.Run "'" & ThisWorkbook.Name & "'!thisworkbook.workbook_open"

Open in new window

and leave it private. Or better still, move the code to a regular module and call it from both locations. ;)
0
 
LVL 43

Author Closing Comment

by:Saqib Husain, Syed
ID: 39621194
Kevin,
Great, thanks. Just what I was looking for.

Rory,
Good to know, thanks.

Saqib
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

A2 = A1 That kind of cell reference is relative.  If you copy it from A2 to B2, then B2 will get this: B2 = B1 That's all fine and good, but if you then insert a new row above row 2, you'll find: A3 = A1 B3 = B1 This is intentional. …
Introduction This Article briefly covers methods of calculating the NPV and IRR variants in Excel as well as the limitations in calculating and interpreting IRR results. Paraphrasing Richard Shockley, author of my favourite finance reference tex…
The viewer will learn how to simulate a series of coin tosses with the rand() function and learn how to make these “tosses” depend on a predetermined probability. Flipping Coins in Excel: Enter =RAND() into cell A2: Recalculate the random variable…
This Micro Tutorial will demonstrate how to use a scrolling table in Microsoft Excel using the INDEX function.

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now