.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
david stephan
Gaurav Pal
Post New Web Links

Word automation under asp.net 1.1.4322 & Vista 64-bit

Posted By:      Posted Date: August 28, 2010    Points: 0   Category :.NET Framework
(this problem was solved, please refer to my later reply down in this thread)We have an asp.net 1.1.4322 application running successfully under Windows XP Pro 32-bit , Windows Server 2003 32-bit and Windows Vista Ultimate 32-Bit.In this application we are successfully generating/saving/opening Word documents, and we were able to successfully upgrade from Word 2000 to Word 2007 without problems, under both platforms.When installing and running the same application under Vista SP1 64-bit we faced a problem with automating Word. We tried giving all permissions possible, we tried impersonating in Web.Config, we tried running the IIS process as Administrator, we searched the internet and tried many solutions we found out there, but nothing seemed to fix the problem.Investigating under Task Manager, I can see that WINWORD is launched as:"C:\Program Files (x86)\Microsoft Office\Office12\WINWORD.EXE" /Automation -Embeddingbut the code crashes at a line like this:oDoc = oWord.Documents.Add(ref documentTemplate, ref oMissing, ref oMissing, ref oMissing);Generating this error:COMException (0x800a13e9): Word has encountered a problem.I have a feeling that this has to do with 32-bit/64-bit system dlls related to the Dcom Launcher, and during my search I came across this article which suggested checking some dlls and making sure they match the same version:http://support.microsoft.

View Complete Post

More Related Resource Links

Word Automation Issue in Windows Server 2008 Hosting



The problem I am posting here is that I was facing nearly 2 weeks around. Any body comes with this stuff please help.

Word Automation in sample ASP.NET(C#) application.

I am using Microsoft.Office.Inetrop.Word Assembly for automation. Here I am reading a XXX.dot template file and fill the contents with dynamic data.

When i am executing my code in localhost:someportnumber the automation is working fine and I could get expected result and when I am hosting in my inetmgr(Windows XP is my OS) it is also working fine.

But the problem is that when I am hosting in my production server(Windows Server 2008 Standard Edition) I am not able to perform automation and results in the following error.

Data: System.Collections.ListDictionaryInternal
Message: Word has encountered a problem.
Source: Microsoft Word

The code gets failed in the following line:

ApplicationClass wordApp = new Microsoft.Office.Interop.Word.ApplicationClass();

Document wordDoc = wordApp.Documents.Add(ref oTemplate, ref oFalse, ref oMissing, ref oMissing); // Error in this line

I cannot able to proceed further. Can anybody please help me in solving this issue?

Thank you.

With Regards,


Word Automation - Multiple DCOM Errors/Behavior

Before I get started, I already know that Microsoft does not support and highly discourages server-based MS Office automation.  I've read a multitude of posts and smarmy "*wink*, here's a link" replies, so I'm looking for actual help here, not condescending reprimands.

That notwithstanding, here is my problem.  I have developed a simple method that will open a local Word document, modify some header information, and then save the document as a new file.  As expected, it works great as a console/windows app, but as soon as I went to ASP.NET, DCOM jacked my world up when accessing the app remotely from a different domain account (that has access to the ASP.NET app.  For reference, my method is shown below:


1    public static string ModifyAndSaveBuildDocument(string localFilePath, BuildDocumentType docType, string buildNumber, DateTime buildDate, string projectName)
2            {
3                try
4                {
5                    ProjectConfiguration config = (ProjectConfiguration)ConfigurationManager.GetSection("ProjectConfiguration");

Developing with SharePoint 2010 Word Automation Services

Using the Open XML SDK 2.0 in combination with Word Automation Services enables many scenarios that are difficult when using only the Open XML SDK 2.0, such as repagination, conversion to other document formats, or updating dynamic content in documents.

Developing Applications in SharePoint 2010 Using Word Automation Services and Excel Services

Learn about the new client services features that are available in SharePoint Server 2010, including Word Automation Services and Excel Services.

Sample: Developing Applications in SharePoint 2010 Using Word Automation Services and Excel Services

Download sample code that demonstrates the new client services features that are available in SharePoint Server 2010, including Word Automation Services and Excel Services.

Sample: Converting Word Documents to PDF using SharePoint Server 2010 and Word Automation Services

Explore the code in this visual how-to article as you learn how to programmatically convert Word documents to PDF format on the server by using Word Automation Services with SharePoint Server 2010.

asp.net 2.0 word automation issue


i 've VS2005 (asp.net 2.0) and i'm developing a intranet applcaition.

i want to create/open word files on the client side , that can be editable and can be saved on to the database.

all of the client systems will have Word 2007 installed. please suggets what approach should i take.

i tried with COM word automation but there are a lot of security/permissions issue associated and its not working fine.

please advise.

thanks in advance







Does Word Automation Services require Office 2010 install on server to function?


Subject is the question.


My requirements are to "maintain existing functionality with current version of a windows service running on Server 2003 and automating Word through COM."   I.E. All the stuff that breaks when you upgrade the OS to Server 2008.  

My customer has already rejected several third party alternatives as "not being accurate enough"  The rendered PDF doesn't match what comes out of Word when compared with an electron microscope.

So now I'm investigating using Word Automation Services and Sharepoint 2010.   Got my development server functional with Sharepoint 2010 and Visual Studio 2010.  But my first attempts at creating rendering jobs is failing with an "ArgumentNullException" in deep inside a method I'm 100.0% sure I'm NOT passing any NULL's to. 

My VM is low on space so I figure I'd save time by asking for a conclusive answer before I make room / install Office.

Opening Word without Automation in ASP.net C#


Hi all,

I am been having trouble with finding an answer to this question but here goes:

Is there any way to write to MSWORD without automation through ASP.NET in C# (maybe write to an existing word document without opening it)?

I am pulling my hair out! I have tried adding IUSR, ASPNET to the web server, I have tried Identity Impersonate = True in the web.config.

My code for opening word looks like this:

object isVisible = true;
object readOnly = true;

I get a Macro storage error on the open statement. I have put a lot of time into figuring this out and I really dont want to do a TOTAL 180.

wordDoc = WordObj.Documents.Open2000(ref fileName, ref missing, ref readOnly, ref missing, ref missing, ref missing, ref missing, ref missing, ref missing, ref missing, ref missing, ref isVisible);

I appreciate any ideas or suggestions given! 

 Thank you in advance!


Word Automation Services


we want to use the Word Automation Services in Sharepoint. Therefore I tried to configure a new Word Automation Service like described in this msdn article ( http://msdn.microsoft.com/en-us/library/ee557330(office.14).aspx) but I can't find the option new->"Word Conversion Service Application".

I can only create a new connection to a word service application proxy. Could it be that I missed to install it during the configuration wizzard?
Or do I use the wrong Version of Sharepoint 2010? What is the difference between "Sharepoint 2010 Enterprice CAL Feature" and "Sharepoint 2010 for Internetsites"?



COM exception on Win-2003 STD Edition SP2 (For Word Automation)


Hi there,


I have deployed my Web Application (.Net framework 2.0) on Windows Server-2003 STD Edition SP2

and i have also given the Administrator impersonation into web.config

"<identity impersonate="true" userName="user-name" password="password"/>"


and am developing and Word Automation Application which contains only 3 lines of code for time being

 object oMissing = System.Reflection.Missing.Value;
 Microsoft.Office.Interop.Word.ApplicationClass oWord = new Microsoft.Office.Interop.Word.ApplicationClass();
 oWord.Quit(ref oMissing, ref oMissing, ref oMissing);


with the referenc library Microsoft.Ofiice.Interop.Word


which works fine into local system when given with impersonation,   but when deployed the same application onto server and i have also given the server Administrator impersonation but also its not allowing me to access the COM factory and its throwing me the error as


Retrieving the COM class factory for component with CLSID {000209FF-0000-0000-C000-000000000046} failed due to the following error: 80040154.



am not getting still what more security issue i need to configure onto

Word Automation through Windows service (Windows Server 2008) - Problem

I went through the thread in this link http://social.msdn.microsoft.com/Forums/en-US/netfx64bit/thread/65a355ce-49c1-47f1-8c12-d9cf5f23c53e (which is a very similar problem to mine), but couldnt solve my problem.
I seem to face a very related problem in word automation.
I have created a windows service which creates a sample word document (WORD 2007) and then converts it to a .doc file (WORD 2003 format) or a PDF file , based on requirement.  Let me post the sample code here :

Chapter 10: Word Automation Services (SharePoint 2010 Web App The Complete Reference)

Learn how to build Word web-based applications in Microsoft SharePoint 2010 by using OpenXML.

New Content on Excel Services and Word Automation Services Development for SharePoint Server 2010 (B

Check out the new visual how-to videos and articles that showcase how to create interactive solutions around Excel Services in SharePoint 2010, as well as book excerpts for Excel Services and Word Automation Services.

Excel Automation in .Net

Excel Automation is a buzz word in both webapps and winapps. In the programming life (like Mr.Anderson neo) I guess almost every one could have come across this word. For others let me go further in detail. Excel Automation is automating some or all of the process involved in creating or updating excel worsheets.

How to run Office macros by using Automation from Visual Basic .NET

This step-by-step article describes how to call Office macros from a Visual Basic .NET Automation client.

You can use Microsoft Office Automation to open a document or create a new document that contains a Visual Basic for Applications (VBA) macro and execute the macro at run time.

PrintPocketCE Print Pocket Excel, Pocket Word and email files

Version 3.560 (May 15, 2009):

Important bug fix: a slight difference in how some devices create fonts was causing a few devices to have significantly longer print times for large print jobs.

Adjusted PocketJet printer paper feed commands

Other minor fixes and enhancements.

Version 3.559 (Mar 5, 2009):

Added support for Martel MCP78xx printers

Version 3.558 (Aug 20, 2008):

Added support for Martel MCP78xx printers

Version 3.557 (June 27, 2008):

Fixed error in Canon printer support

Fixed COM0 port selection

Version 3.556 (June 15, 2008):

Added support for Brother MW-260

Added support for Sato MB400

Version 3.555 (Aug 8, 2007):

Added support for Pentax RuggedJet 3 and RuggedJet 4 printers

Changed Epson TM-P60 support to maximum page width of 1200 dots

Version 3.551 (Aug 1, 2006):

Added Peripheral Nomad printer support

Version 3.550 (Mar 23, 2006):

Added Panasonic JT-H200PR printer support

Added Pocket Spectrum printer support

Fixed problem with WM5.0 "inverted image" problem
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend