18. Server Data Scenarios

Populating a Document with Data on the Server

Consider the following portion of an all-too-common server scenario. An authenticated user, perhaps a salesperson, requests an Excel spreadsheet from a server. The spreadsheet is an expense report, and the server is an ASP, ASP.NET, or SharePoint server. The server code looks up some information about the user from a database, Active Directory, or Web service. Perhaps the server has a list of recent corporate credit card activity that it will prepopulate into the expense list. The server starts Excel but keeps it “invisible” because there is no interactive user on the server. Then it uses the Excel object model to insert the data into the appropriate cells, saves the result, ...

Get Visual Studio Tools for Office: Using Visual Basic 2005 with Excel, Word, Outlook, and InfoPath now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.