protect and share file

S

syaronc

Hi all,
i am using a vba code on my main file so when it is opened
another file will be opened with him , this works perfectly as long as
i dont activate the "Protect and Share Workbook" option. when i start
this option the vba code doesn't run any more and i must have this
option for multiple users....

Does anyone have any idea why it happens?

Thanks Yaron.
 
D

Dave Peterson

In a simple test (book1.xls controlled the opening of book2.xls), this code
worked if the book1 were shared or not shared:

Option Explicit
Private Sub Workbook_Open()
Workbooks.Open Filename:="C:\my documents\excel\book2.xls"
End Sub
(under the ThisWorkbook module)

And it worked when I protected and shared turned on track changes, too.

What did your code look like that failed?
 
S

syaronc

my code looks exactly the same.....
it seems to me now that the code won't work if i have links to the fil
i am trying to open . Any idea why it happens?

Yaron
 
D

Dave Peterson

No.

I couldn't get it to not work.

Does it work on a couple of test workbooks?

I used xl2002. If you're using a different version, post that version. Maybe
someone can test it against that same version of excel.
 
S

syaronc

thanks for the effort,
it doesn't work with test workbooks as well,
My excel version is "Excel 2000 sp-1"
if anyone has any idea i'll be glad
Yaron
 
D

Dave Peterson

It might make it easier for others if you can trim your code down to its bare
necessities and post it.
 
Top