Zoom Down in EXCEL from an ASP.NET application

dadit

New Member
Can anybody tell me how to set the zoom factor on an Excel sheet via a ASP.NET application. I believe the Excel Sheet object has a PageSetup.Zoom property which does not seem to be working. When I generate a report in Excel programatically through ASP.NET I get the zoom factor of all sheets in the workbook as 100%. Here is a code sample\[code\]oSheet.PageSetup.CenterHorizontally = true;oSheet.PageSetup.CenterVertically = true;oSheet.PageSetup.Orientation = XlPageOrientation.xlPortrait;oSheet.PageSetup.PaperSize = XlPaperSize.xlPaperA4;oSheet.PageSetup.Order = XlOrder.xlDownThenOver;oSheet.PageSetup.Zoom = 85;\[/code\]Another option is ActiveWindow.Zoom as generated by a macro but it is macro-specific. The whole point of asking this question is after the report has been generated the zoom factor of all the pages in the Excel workbook should be 85%.Any inputs would be highly appreciated.
 
Top