Hi
I Build a Excel File using VB as below
I tried to open excel using shellCode:'--------------------' ' Instancia Excel ' '--------------------' Set objXl = CreateObject("Excel.Application"): objXl.Visible = False '--------------------' ' Abre Novo Arquivo ' '--------------------' Set objBook = objXl.Workbooks.Open(sNovo_Arquivo, , , , "") Set objSheet = objBook.ActiveSheet objSheet.Cells(4, 1).CopyFromRecordset rsEvento ', 65536 '------------------------- ' Salva planilha '------------------------ Set objSheet = Nothing objBook.Close SaveChanges:=True Set objBook = Nothing objXl.Quit Set objXl = Nothing
Is there other way to open Excel without to let excel object opened inside VB ?Code:shell sNovo_Arquivo![]()




Reply With Quote