motormad Posted March 3, 2011 Share Posted March 3, 2011 Can somebody explain to me why sometimes local $oExcel = ObjGet($FilePath); Create an Excel Object If @error Then MsgBox(0, "Excel Error:", "Error creating Excel object!") Exit EndIf If Not IsObj($oExcel) Then MsgBox(16, "Excel Error:", "Error creating Excel object!") Exit EndIf $oExcel.Windows (1).Visible = 1; Set the first worksheet in the workbook visible $oExcel.Worksheets (1).Activate $oExcel.ActiveSheet.Visible = 1 $oExcel.Application.Visible = 0 is used in the place of $oExcel = _ExcelBookOpen($FilePath) thanx Link to comment Share on other sites More sharing options...
MrMitchell Posted March 3, 2011 Share Posted March 3, 2011 Can somebody explain to me why sometimes local $oExcel = ObjGet($FilePath); Create an Excel Object If @error Then MsgBox(0, "Excel Error:", "Error creating Excel object!") Exit EndIf If Not IsObj($oExcel) Then MsgBox(16, "Excel Error:", "Error creating Excel object!") Exit EndIf $oExcel.Windows (1).Visible = 1; Set the first worksheet in the workbook visible $oExcel.Worksheets (1).Activate $oExcel.ActiveSheet.Visible = 1 $oExcel.Application.Visible = 0 is used in the place of $oExcel = _ExcelBookOpen($FilePath) thanx The former doesn't use the Excel UDF and where ever you see it might just be a little older code. The later does. Just another way of doing it. Link to comment Share on other sites More sharing options...
motormad Posted March 4, 2011 Author Share Posted March 4, 2011 Thanx I better not use it then :-) Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now