>any idea why that would cause it to throw the C0000005 error on the open line?
>
>printing is required unfortunatly, these are jobsheets which are required for production rooms, I used to get the crash on the printline but I updated excel and the printdrivers and it stopped doing that, the only places it crashes now is on that open line and on the bit to select shaperange.
>
>so this line
>
>oworkbook = oExcel.workbooks.open(alltrim(basevars.baseljb) + "LaserJobbag.xls")
>
>
>or one of these lines
>
>oworkbook.worksheets(1).Shapes.selectall
>oexcel.selection.shaperange.visible = 0
>
>
>and
HERE is my crash
C...5 type errors *can* typically be attributed to referencing memory that doesn't belong to you or has been released. In this case, it may be something actually in the spreadsheet that's not 100% compatible with the version of Excel you're trying to open it in.