none
Office 2007 PIA - deployment problem RRS feed

  • Question

  • Hi to all,

    i am having trouble with deploying a word 2007 automation project, from one machine to another. The source code is written in c# 2.0 while using PIA 2007 assemblies.

    The code does some word 2007 automation and on machine Num 1. (where eveything works fine ) i have the following "prerequisites" installed :
    1. Visual studio 2005
    2. Office 2007 Enterprise
    3. PIA 2007
    4. VSTO 2005 SE
    5. Office 2007 Add in Save as PDF
    Machine Num 2. has he exact same software installed with the exception the i have Office 2007 Standard edition  there.

    This is the error that i get on the second computer and so far (today ) i havent been able to resolve it.

    ErrorCode : -1073741819
    
    Message : Exception from HRESULT: 0xC0000005
    
    Stack  Trace :
    
       at Microsoft.Office.Interop.Word.
    Find.get_Replacement()
       at CleanTest2007.Program.Main(String[] args) in C:\Documents and Settings\bpm\Desktop\BarkodGenerator\TestWordCreator\CleanTest2007\Program.cs:line 43
       at System.AppDomain.nExecuteAssembly(Assembly assembly, String[] args)
       at System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args)
       at Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()
       at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
       at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
       at System.Threading.ThreadHelper.ThreadStart()

    i have succesfully referenced Microsoft Office 12.0 Word Object Library ( in the COM tab ) on the problematic machine.


    The error appears on the line where i call upon the Replace.Text property of the Microsoft.Office.Interop.Find object.

    Do i need to register smth more with regsrv32 ?

    Any help is appreciated.

    Tomislav

    Thursday, June 4, 2009 5:30 PM

Answers

  • Problem solved with implementing late binding on the  Find object.

    Solution was extracted from this article :

    http://support.microsoft.com/kb/313104

    Cheers,
    Tomislav


    • Marked as answer by Tim Li Thursday, June 11, 2009 5:46 AM
    Friday, June 5, 2009 8:45 AM

All replies