R
Richard
I have written code to create an instance of Excel and
then use the GetObject to open a file. Everything is oK
until the XL file is being opened at which time the
prompt for 'do you wish to enable/disable macros'
appears'. On choosing 'yes' the code crashes with Error
#13 Type Mismatch. sample code below
Dim objXL As New Excel.Application
Dim Path As String
Set objXL = GetObject(Path, "Excel.Sheet")
objXL.Visible = True
then use the GetObject to open a file. Everything is oK
until the XL file is being opened at which time the
prompt for 'do you wish to enable/disable macros'
appears'. On choosing 'yes' the code crashes with Error
#13 Type Mismatch. sample code below
Dim objXL As New Excel.Application
Dim Path As String
Set objXL = GetObject(Path, "Excel.Sheet")
objXL.Visible = True