Hi,
Iam generating a Excel file using interop services.I could save the file to my server. When i try to print using the below code it is printed if i run locally.
worksheet.PrintOut(Type.Missing, Type.Missing, Type.Missing, Type.Missing,
Type.Missing, Type.Missing, Type.Missing, Type.Missing)
If i host the application in IIS ,i get error at this part of the code
Microsoft Office Excel cannot access the file 'D:\file.xls'.
Workbook.Open(filePath,
Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing,
Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing,
Type.Missing, Type.Missing, Type.Missing, Type.Missing);
I use server.mappath to save the file.
Suggestions please.
Thanks in advance