Check if Excel file is password protected
The follwing code throws up a prompt for a password when the Excel file is
password protected (it is vb.net). ExcelWorkBook = ExcelApplication.Workbooks.Open(ExcelFullName, Nothingobj, True, Nothingobj, Nothingobj, Nothingobj, Nothingobj, Nothingobj, Nothingobj, Nothingobj, Nothingobj, Nothingobj, Nothingobj, Nothingobj, Nothingobj) How do I detect in code (vb.net or c#) if an Excel workbook is password protected when I get the prompt for password at the same time I am trying to open it? |
All times are GMT +1. The time now is 07:17 AM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com