I have a little doubt here... how to open an Excel file protected by a password? I tried this:
- Code: Select all Expand view
oExcel := TOleAuto():New( "Excel.Application" )
if Ole2TxtError() # "S_OK"
MsgInfo("EXCEL não está instalado nesta máquina."+CRLF+"Impossível gerar planilha","ATENÇÃO")
return nil
endif
oExcel:Workbooks:Open( cDirXLS+cArquivoX, , , ,"1111" )
But it gives me an error. Where am I wrong?
TIA,