From: james on 23 Feb 2010 09:41 Hi, I have the following button. It opens a spreadsheet that is password protected. This spreadsheet has links to another password protected spreadsheet. The button enters the password and sets update links to yes but it then asks for a password to update the links I would like it to input the password automatically. Can Anyone help please? Thanks Private Sub Command1_Click() On Error GoTo Err_Command1_Click Dim ExcelApp As Object 'Excel.Application Dim ExcelWkb As Object 'Excel.Workbook Set ExcelApp = CreateObject("Excel.Application") Set ExcelWkb = ExcelApp.Workbooks ExcelWkb.Open "C:\Test.xls", , , , "ABCDE", UpdateLinks:=1 ExcelWkb.Close ExcelApp.Quit Set ExcelWkb = Nothing Set ExcelApp = Nothing Exit_Command1_Click: Exit Sub Err_Command1_Click: MsgBox Err.Description Resume Exit_Command1_Click End Sub
|
Pages: 1 Prev: Dynamically moving from one form to another Next: Save Record |