locked
How to deploy a reference to a remote server? RRS feed

  • Question

  • User1858984285 posted

    Hi Experts!

    I am using the Microsoft.Office.Interop.PowerPoint reference in my code.

    Referencing it in my code on my local machine, it works. However, when I want to deploy, I don’t know where the reference binary is located. I added it using VS Express 2013 for Web and its Reference Manager. But when I checked my project files (including the bin folder), I don’t see the reference added. Anyhow, I copied all of the files to the remote server, but it didn’t resolve my breaking code, so apparently the reference in question isn’t there.

    So where and how can I deploy the reference? Or do I need to somehow package it up?

    Please advise. Thank you!

    Tuesday, December 10, 2013 11:19 PM

Answers

  • User753101303 posted

    Hi,

    And how your code breaks exactly ? The issue is more likely that Microsoft.Office.Interop.PowerPoint is a bridge to PowerPoint and requires PowerPoint to be installed. This is strongly discouraged as Office apps were never intended to be automated server side and making it right is not as easy as deploying a DLL: http://support.microsoft.com/kb/257757

    It would have been better to use the OpenXML SDK or a third party library such as Aspose.Slides to handle PowerPoint files...

    When your code breaks, please always tell exactly how. It allows to start from the actual error you have rather than guessing.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Wednesday, December 11, 2013 3:52 AM

All replies

  • User753101303 posted

    Hi,

    And how your code breaks exactly ? The issue is more likely that Microsoft.Office.Interop.PowerPoint is a bridge to PowerPoint and requires PowerPoint to be installed. This is strongly discouraged as Office apps were never intended to be automated server side and making it right is not as easy as deploying a DLL: http://support.microsoft.com/kb/257757

    It would have been better to use the OpenXML SDK or a third party library such as Aspose.Slides to handle PowerPoint files...

    When your code breaks, please always tell exactly how. It allows to start from the actual error you have rather than guessing.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Wednesday, December 11, 2013 3:52 AM
  • User1858984285 posted

    Hi PatriceSc, thank you for your help!

    PatriceSc

    This is strongly discouraged as Office apps were never intended to be automated server side and making it right is not as easy as deploying a DLL: http://support.microsoft.com/kb/257757

    Yikes! Ok, I will look at the alternatives you listed. My co-worker in the past installed Office on the server, but I see now that it is not recommended.

    PatriceSc

    When your code breaks, please always tell exactly how. It allows to start from the actual error you have rather than guessing.

    I apologize. Here is the error message:

    Error Message

    Text version

    Compilation Error
    Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.
    
    Compiler Error Message: CS0234: The type or namespace name 'Office' does not exist in the namespace 'Microsoft' (are you missing an assembly reference?)
    
    Source Error:
    
    Line 4:
    Line 5:
    Line 6: using Microsoft.Office.Interop.PowerPoint;
    Line 7:
    Line 8:
    
    Source File: d:\hosting\9236287\html\DataEntry\MapWise\App_Code\Converter.cs Line: 6

    It clearly shows that Office is not installed on the Remote server (in addition to the PowerPoint reference not found). And even after installing Office, I’ll have to do what your article said.

    But I’ll check out the alternatives.

    Thank you!

    Wednesday, December 11, 2013 11:35 AM