Hi All,
I am Getting an error like "This operation is not supported in the current context." while Creating an object of Excel.Application in the Following Code.
excelApp = AutomationFactory.CreateObject("Excel.Application");
Can anyone help on this please why this error is coming.
Thanks,
Prasant

Priya LingePosted Aug 8, 2011, 8:25 AM
I used both solution in my application,it works here.
Please check attached file.
Thanks.
Prasant JinagaPosted Aug 8, 2011, 7:25 AM
Priya LingePosted Aug 8, 2011, 5:22 AM
Please mark Require elevated trust when running outside browser ,which in Out-Of-Browser setting window.
Prasant JinagaPosted Aug 8, 2011, 5:02 AM
I already Enabled Running out of Browser checkbox.
Thanks,
Prasant
Priya LingePosted Aug 8, 2011, 4:37 AM
You should be check the outofBrowsersetting in your application.
Please mark it as Enable running application out of Browser.
Thanks.