kiranboi
asked on
Protected Memory Error When Using Automation to Control Excel
Hi all,
I have written a little utility that prints out information in a certain format by using automation to insert the data into an Excel template and then print to the default printer from Excel.
This has all been working fine. I have now upgraded the utility slightly and now, even though I havn't changed the automation part, whenever my app tries to open an Excel file I get an error saying: I have attmepted to read or write protected memory. This then stops my app from working.
Does anyone know why this is happening and what I can do to fix it?
Many Thanks.
I have written a little utility that prints out information in a certain format by using automation to insert the data into an Excel template and then print to the default printer from Excel.
This has all been working fine. I have now upgraded the utility slightly and now, even though I havn't changed the automation part, whenever my app tries to open an Excel file I get an error saying: I have attmepted to read or write protected memory. This then stops my app from working.
Does anyone know why this is happening and what I can do to fix it?
Many Thanks.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Ok great...
Please close the Q if this helped...
Please close the Q if this helped...
ASKER
I found a previous question on EE telling me to change from early binding to late binding and it works great now.
Thanks