ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Replacing a password protected file. (https://www.excelbanter.com/excel-discussion-misc-queries/225609-replacing-password-protected-file.html)

JEV

Replacing a password protected file.
 
Is it correct that I can save over a password protected file (password
needed to modify or open) with a file with the same name? What am I missing.
Is there a way to avoid this?

Bernie Deitrick

Replacing a password protected file.
 
JEV,

You need to mark the file as Read Only, either through Windows Explorer (right click etc.), or
through code (with the file closed)

SetAttr "C:\Path\File to be read only.xls", vbReadOnly

HTH,
Bernie
MS Excel MVP


"JEV" wrote in message
...
Is it correct that I can save over a password protected file (password
needed to modify or open) with a file with the same name? What am I missing.
Is there a way to avoid this?





All times are GMT +1. The time now is 07:10 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com