#1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 53
Default Open WB

Using winxp pro and msoffice 2003

I am using this code to open a workbook and it does the job I am asking it
to do alright, only what I really want to do is open a copy of this workbook,
and set the read only attribute to false.
I tried putting this at the end of the statement ;read only = false but that
doesn't work.

Workbooks.Open ("C:\Documents and Settings\joanne\Desktop\ _
Linking Project\Outlook Master Pricing.xls")

Could someone please show me the proper syntax for opening a wb as a 'copy
of wb' and setting the read only attribute to false?

Thank you for your help

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10,593
Default Open WB

what do you mean by a copy of wb? Do you already have it open?

--
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)

"Joanne" wrote in message
...
Using winxp pro and msoffice 2003

I am using this code to open a workbook and it does the job I am asking it
to do alright, only what I really want to do is open a copy of this
workbook,
and set the read only attribute to false.
I tried putting this at the end of the statement ;read only = false but
that
doesn't work.

Workbooks.Open ("C:\Documents and Settings\joanne\Desktop\ _
Linking Project\Outlook Master Pricing.xls")

Could someone please show me the proper syntax for opening a wb as a 'copy
of wb' and setting the read only attribute to false?

Thank you for your help



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 53
Default Open WB

Bob
No, it is not yet open. It is a master pricing ws and I don't want any
changes made to it - so I want to open a copy of it for my user, run my code
on the copy to hide info user does not need for current job, allow user to
manipulate the rest of the data, all the while the master is safe. When user
is done with the job, the 'copy of the workbook' is dumped.

I think that my code will not run on the master anyway (in my tests using an
old version of the master) because the master is 'read only' - am I correct
in thinking that this is the reason I cannot hide any of the columns. That is
why I need to know how to open the 'copy of wb' and change the attribute to
'read' from 'read only'.

Bob, thank you for your time and consideration of my little dilemma. I sure
appreciate it a lot
Joanne

"Bob Phillips" wrote:

what do you mean by a copy of wb? Do you already have it open?

--
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)

"Joanne" wrote in message
...
Using winxp pro and msoffice 2003

I am using this code to open a workbook and it does the job I am asking it
to do alright, only what I really want to do is open a copy of this
workbook,
and set the read only attribute to false.
I tried putting this at the end of the statement ;read only = false but
that
doesn't work.

Workbooks.Open ("C:\Documents and Settings\joanne\Desktop\ _
Linking Project\Outlook Master Pricing.xls")

Could someone please show me the proper syntax for opening a wb as a 'copy
of wb' and setting the read only attribute to false?

Thank you for your help




  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4,391
Default Open WB

Is the file is marked as read-only in Windows: Right-click on the file in
Explorer, select properties, at the bottom, is the Read Only attribute set ?
If so, you can open it and make any changes you want, but the user will not
be able to save to file as that name; they will be able to do a .SaveAs, but
that will not affect the original.

Sounds like you may have the workbook and/or the worksheet(s) protected;
ToolsProtection.

NickHK

"Joanne" wrote in message
...
Bob
No, it is not yet open. It is a master pricing ws and I don't want any
changes made to it - so I want to open a copy of it for my user, run my

code
on the copy to hide info user does not need for current job, allow user to
manipulate the rest of the data, all the while the master is safe. When

user
is done with the job, the 'copy of the workbook' is dumped.

I think that my code will not run on the master anyway (in my tests using

an
old version of the master) because the master is 'read only' - am I

correct
in thinking that this is the reason I cannot hide any of the columns. That

is
why I need to know how to open the 'copy of wb' and change the attribute

to
'read' from 'read only'.

Bob, thank you for your time and consideration of my little dilemma. I

sure
appreciate it a lot
Joanne

"Bob Phillips" wrote:

what do you mean by a copy of wb? Do you already have it open?

--
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my

addy)

"Joanne" wrote in message
...
Using winxp pro and msoffice 2003

I am using this code to open a workbook and it does the job I am

asking it
to do alright, only what I really want to do is open a copy of this
workbook,
and set the read only attribute to false.
I tried putting this at the end of the statement ;read only = false

but
that
doesn't work.

Workbooks.Open ("C:\Documents and Settings\joanne\Desktop\ _
Linking Project\Outlook Master Pricing.xls")

Could someone please show me the proper syntax for opening a wb as a

'copy
of wb' and setting the read only attribute to false?

Thank you for your help






Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
ON OPEN VBA Code input incorrectly now excel sheet wont open mmartin New Users to Excel 1 February 16th 11 11:33 PM
Opening Excel, Book1 opens, remains open with other workbook open DanieB Excel Discussion (Misc queries) 0 September 3rd 09 08:23 AM
excel 2003 saved file will not open without a blank workbook open Bob Excel Discussion (Misc queries) 4 November 11th 06 04:24 PM
Open workbook macro- find correct month to open? buzzharley[_10_] Excel Programming 8 July 8th 06 04:30 AM
workbooks.open function fails to open an existing excel file when used in ASP, but works in VB. san Excel Programming 1 January 3rd 06 03:22 AM


All times are GMT +1. The time now is 01:08 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"