One of my requirement was to create a automated job which needs to be placed in the scheduled task of the Server.
I have written the code on Windows Form Load job performs below activities.
1. Calls a 2 stored procedure (MS-SQL)
2. Stores data in couple of datatables
3. This 2 datatables are passed to function which exports to excel and stores in a path.
I have used "using Excel = Microsoft.Office.Interop.Excel"
Excel.Application xlApp ;
Where I am storing the output in a workbook with 2 sheets (2 tabs). I have also used some of the Excel features like.
xlWorkSheet1.Name = "Completed_Projects";
Now everything is working as expected in my local system. When I ran the exe on test server I found that MS-Office Excel needs to be installed on the server to use this Excel object features.
Server Team are not ready to install the MS-Office on server nature of Office it presents additional attack vectors that potentially risk their security and Office may exhibit unstable behavior and/or deadlock when Office is run in server environment.
Could someone let me know alternative way used Export to Excel (with datatable\datagridview as source) and save in particular path?
I need to have features like Auto Alignment of column width, able to store two worksheet in single workbook, name the worksheet.
Entering time in Microsoft Access can be difficult. An input mask often bothers users more than helping them and won't catch all typing errors. This article shows how to create a textbox for 24-hour time input with full validation politely catching …
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel.
Part 1 of this series discussed basic error handling code using VBA.
Enter Foreign and Special Characters
Enter characters you can't find on a keyboard using its ASCII code ... and learn how to make a handy reference for yourself using Excel ~
Use these codes in any Windows application! ... whether it is a Micr…