Solved

Share Workbook with Macro?

Posted on 2009-04-07
3
482 Views
Last Modified: 2013-11-25
Hi Experts-

I have several workbooks that I run simple formatting macros on.  In one of the final macros, I'd like to add code that converts the file to a shared workbook.  Is this possible?  Any help would be appreciated.  Thanks.

Q

P.S. I've tried searching for my answer in the knowledgebase, but wasn't able to find something general enough to be my solution.
0
Comment
Question by:quaziblue
3 Comments
 
LVL 92

Assisted Solution

by:Patrick Matthews
Patrick Matthews earned 125 total points
ID: 24093150
Hello quaziblue,

The consensus opinion of Experts here is that using 'share workbook' should be assiduously
avoided.  This is a poorly implemented feature in Excel that leaves workbooks highly
vulnerable to corruption.  If true multi-user capability truly is needed, then the best practice
is to use a database platform such as Access, SQL Server, MySQL, etc.

Regards,

Patrick
0
 
LVL 85

Accepted Solution

by:
Rory Archibald earned 175 total points
ID: 24094561
I totally agree with Patrick as regards the reliability of Shared Workbooks but I know that there are situations where you have no choice so, for the record, you could use code like that below. Avoid it if possible though!
Rory

Sub ShareWorkbook()

   Application.DisplayAlerts = False

   ActiveWorkbook.SaveAs ActiveWorkbook.FullName, accessmode:=xlShared

   Application.DisplayAlerts = True
 

End Sub

Open in new window

0
 
LVL 1

Author Closing Comment

by:quaziblue
ID: 31567825
Thanks for the responses.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This tutorial explains how to create a series of drop-down lists that are dependent upon prior selections to guide (“force”) the user to make the correct selection and reduce data errors within Microsoft Excel. Excel 2010 was used for this tutorial;…
This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
The viewer will learn how to use the =DISCRINV command to create a discrete random variable, use this command to model a set of probabilities and outcomes in a Monte Carlo simulation, and learn how to find the standard deviation of a set of probabil…
The viewer will learn how to create a normally distributed random variable in Excel, use a normal distribution to simulate the return on an investment over a period of years, Create a Monte Carlo simulation using a normal random variable, and calcul…

920 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

12 Experts available now in Live!

Get 1:1 Help Now