LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming,microsoft.public.vb.general.discussion
external usenet poster
 
Posts: 118
Default Open Excel from VB using Read-Only switch?

I'm trying to get my Visual Basic (6.0, SP4) app to open an Excel 2000 file
as Read-Only. I read two Knowledge Base articles (#211481 and 291288) that
showed the switches used by Excel, and how to build a command line statement
using them. The Read-Only switch was /r, and was shown as /r <filename.
So I put the following in my Run box:
/r "C:\Documents and Settings\emillis\TestFolder\TestBook.xls"

No go. Couldn't find filename "/r"???

So I put:

"C:\Documents and Settings\emillis\TIR 05 May 2004\TestBook.xls" /r

Now it can't find "C:\Documents"???



Can anyone help me with this - or a better - method of opening a specific
Excel file as Read-Only from VB?



Thanks.

Ed


 
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
Excel Files Open Read-Only Don Brownlee Excel Discussion (Misc queries) 5 May 11th 09 03:43 PM
Can't Open a Read-Only file in Excel 03 Josh C Excel Discussion (Misc queries) 0 February 12th 08 10:09 PM
how do you switch from auto open Jay Excel Discussion (Misc queries) 3 July 18th 05 04:29 PM
how do i open a file in excel that is encrypted or read only ian c forde Excel Discussion (Misc queries) 0 March 4th 05 02:43 PM
Read only command line switch Mike K Excel Discussion (Misc queries) 2 January 2nd 05 03:57 PM


All times are GMT +1. The time now is 03:08 AM.

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"