none
Error while installing VSTO file - A device attached to the system is not functioning. (Exception from HRESULT: 0x8007001F). RRS feed

  • Question

  • When I try install our VSTO (outlook) file on machine 1 for user a, it works fine but for user b it gives below exception.
    Log Name:      Application
    Source:        VSTO 4.0
    Date:          03/10/2016 12:50:59
    Event ID:      4096
    Task Category: None
    Level:         Error
    Keywords:      Classic
    User:          N/A
    Computer:      NAME_OF_COMPUTER
    Description:
    Customization URI: file:///C:/Program Files (x86)/MAIN_FOLDER/SUB_FOLDER/OUTLOOK PLUGIN.vsto
    Exception: A device attached to the system is not functioning. (Exception from HRESULT: 0x8007001F)
    
    
    ************** Exception Text **************
    System.Runtime.InteropServices.COMException (0x8007001F): A device attached to the system is not functioning. (Exception from HRESULT: 0x8007001F)
       at Microsoft.VisualStudio.Tools.Applications.Deployment.ClickOnceAddInDeploymentManager.DownloadAddIn(TimeSpan timeout)
       at Microsoft.VisualStudio.Tools.Applications.Deployment.ClickOnceAddInDeploymentManager.InstallAddIn()
    
    
    ************** Loaded Assemblies **************
    mscorlib
        Assembly Version: 4.0.0.0
        Win32 Version: 4.0.30319.1026 (RTMGDR.030319-1000)
        CodeBase: file:///C:/Windows/Microsoft.NET/Framework/v4.0.30319/mscorlib.dll
    ----------------------------------------
    Microsoft.VisualStudio.Tools.Office.Runtime
        Assembly Version: 10.0.0.0
        Win32 Version: 10.0.60724.0
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/Microsoft.VisualStudio.Tools.Office.Runtime/v4.0_10.0.0.0__b03f5f7f11d50a3a/Microsoft.VisualStudio.Tools.Office.Runtime.dll
    ----------------------------------------
    System.Core
        Assembly Version: 4.0.0.0
        Win32 Version: 4.0.30319.233 built by: RTMGDR
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Core/v4.0_4.0.0.0__b77a5c561934e089/System.Core.dll
    ----------------------------------------
    System
        Assembly Version: 4.0.0.0
        Win32 Version: 4.0.30319.1026 built by: RTMGDR
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System/v4.0_4.0.0.0__b77a5c561934e089/System.dll
    ----------------------------------------
    System.Windows.Forms
        Assembly Version: 4.0.0.0
        Win32 Version: 4.0.30319.1032 built by: RTMGDR
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Windows.Forms/v4.0_4.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
    ----------------------------------------
    System.Drawing
        Assembly Version: 4.0.0.0
        Win32 Version: 4.0.30319.1036 built by: RTMGDR
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Drawing/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
    ----------------------------------------
    Microsoft.VisualStudio.Tools.Applications.Hosting
        Assembly Version: 10.0.0.0
        Win32 Version: 10.0.60724.0
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/Microsoft.VisualStudio.Tools.Applications.Hosting/v4.0_10.0.0.0__b03f5f7f11d50a3a/Microsoft.VisualStudio.Tools.Applications.Hosting.dll
    ----------------------------------------
    Microsoft.VisualStudio.Tools.Applications.ServerDocument
        Assembly Version: 10.0.0.0
        Win32 Version: 10.0.60724.0
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/Microsoft.VisualStudio.Tools.Applications.ServerDocument/v4.0_10.0.0.0__b03f5f7f11d50a3a/Microsoft.VisualStudio.Tools.Applications.ServerDocument.dll
    ----------------------------------------
    System.Xml
        Assembly Version: 4.0.0.0
        Win32 Version: 4.0.30319.1026 built by: RTMGDR
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Xml/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.dll
    ----------------------------------------
    Microsoft.VisualStudio.Tools.Applications.Runtime
        Assembly Version: 10.0.0.0
        Win32 Version: 10.0.60724.0
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/Microsoft.VisualStudio.Tools.Applications.Runtime/v4.0_10.0.0.0__b03f5f7f11d50a3a/Microsoft.VisualStudio.Tools.Applications.Runtime.dll
    ----------------------------------------
    System.Deployment
        Assembly Version: 4.0.0.0
        Win32 Version: 4.0.30319.1039 (RTMGDR.030319-1000)
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Deployment/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Deployment.dll
    ----------------------------------------
    System.Configuration
        Assembly Version: 4.0.0.0
        Win32 Version: 4.0.30319.1015 (RTMGDR.030319-1000)
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Configuration/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
    ----------------------------------------
    System.Security
        Assembly Version: 4.0.0.0
        Win32 Version: 4.0.30319.1031 (RTMGDR.030319-1000)
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Security/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Security.dll
    ----------------------------------------
    System.Xml.Linq
        Assembly Version: 4.0.0.0
        Win32 Version: 4.0.30319.1 built by: RTMRel
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Xml.Linq/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.Linq.dll
    ----------------------------------------
    
    
    
    Event Xml:
    <Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
      <System>
        <Provider Name="VSTO 4.0" />
        <EventID Qualifiers="49154">4096</EventID>
        <Level>2</Level>
        <Task>0</Task>
        <Keywords>0x80000000000000</Keywords>
        <TimeCreated SystemTime="2016-10-03T11:50:59.000000000Z" />
        <EventRecordID>1179761</EventRecordID>
        <Channel>Application</Channel>
        <Computer>COMPUTER_NAME</Computer>
        <Security />
      </System>
      <EventData>
        <Data>Customization URI: file:///C:/Program Files (x86)/MAIN_FOLDER/SUB_FOLDER/OUTLOOK PLUGIN.vsto
    Exception: A device attached to the system is not functioning. (Exception from HRESULT: 0x8007001F)
    
    
    ************** Exception Text **************
    System.Runtime.InteropServices.COMException (0x8007001F): A device attached to the system is not functioning. (Exception from HRESULT: 0x8007001F)
       at Microsoft.VisualStudio.Tools.Applications.Deployment.ClickOnceAddInDeploymentManager.DownloadAddIn(TimeSpan timeout)
       at Microsoft.VisualStudio.Tools.Applications.Deployment.ClickOnceAddInDeploymentManager.InstallAddIn()



    Any idea?




    Monday, October 3, 2016 12:30 PM

Answers

  • Hi David,

    We just cracked the issue. We found that "administrator" profile was dodgy. We removed particular profile and created new one, and it worked fine!

    Still we are in process to find out what was “dodgy” about the profile.

    Thanks for your help.

    Wednesday, October 26, 2016 12:45 PM

All replies

  • Hi Bhargav_Gaglani,

    According to your description, this issue is more likely to be related to upgrading rather than installing the add-in. However, we suggest that you download and install Microsoft Visual Studio 2010 Tools and repeat the process once again.

    Thanks for your understanding.
    Tuesday, October 4, 2016 2:49 AM
  • Hi David,

    Thank you for a suggestion, I will surely give it a try. But I could not understand why it is working for one user account and not for another one on a same machine.


    Tuesday, October 4, 2016 6:00 AM
  • Hello Bhargav,

    I don't think the issue is related to VSTO. Instead, it comes from ClickOnce. Just try to reproduce it with any standalone application.

    Anyway, take a look at the similar forum threads discussing the same error message:

    ClickOnce error occurs when upgrading installed ClickOnce app

    A device attached to the system is not functioning


    [custom.development]

    Tuesday, October 4, 2016 12:45 PM
  • Hi Eugene,

    Thank you for the information. I will give it a try. 

    Wednesday, October 5, 2016 6:20 AM
  • Hi David,

    I tried the approach you suggested. I got the latest Microsoft visual studio 2010 tools and re-installed addin but still facing the same error. This error only happens for administrator accounts not for others.

    Thursday, October 6, 2016 4:05 AM
  • Hi Eugene,

    There are other office tools deployed too but they are working fine. Only with this add-in we are facing issue and it is only with administrator account, for other accounts it is working fine.

    Thursday, October 6, 2016 4:06 AM
  • >>>Only with this add-in we are facing issue and it is only with administrator account, for other accounts it is working fine.

    According to your description, ClickOnce requires that you install your solution separately for each user of a computer. Therefore, you should consider using Windows Installer (.msi) if more than one user will run your solution on the same computer.

    For more information, click here to refer about Deploying an Office Solution by Using ClickOnce

    Thursday, October 6, 2016 6:46 AM
  • Hi David,

    We are already using Windows installer (installshield - msi) to deploy package. VSTO file gets loaded automatically for each user login when they starts outlook first time after installation. 

    Thursday, October 6, 2016 9:10 AM
  • Hi Bhargav_Gaglani,

    According to your description, it seems that you have installed VSTO (outlook), but VSTO (outlook) that does not load with administrator account. If so, the 'VSTO_SUPPRESSDISPLAYALERTS' windows environment variable can be set for enabling detailed Outlook and VSTO (Visual Studio Tools for Office) error messages when loading VSTO add-ins.

    For more information, you could refer to How do I enable VSTO error / display alerts

    Please correct me if I have any misunderstandings.

    Thanks for your understanding.
    Friday, October 7, 2016 8:45 AM
  • Hi David,

    Okay I will try to obtain detailed error message by following way you suggested.

    And more information on environment:-

    Plugin is installed on a Microsoft remote desktop services server.

    Friday, October 7, 2016 11:06 AM
  • Hi David,

    I obtained the detailed error as you suggested and it is no different then exception I have posted. Still I am pasting it over here for your reference.

    A device attached to the system is not functioning. (Exception from HRESULT: 0x8007001F)
    
    
    ************** Exception Text **************
    System.Runtime.InteropServices.COMException (0x8007001F): A device attached to the system is not functioning. (Exception from HRESULT: 0x8007001F)
       at Microsoft.VisualStudio.Tools.Applications.Deployment.ClickOnceAddInDeploymentManager.DownloadAddIn(TimeSpan timeout)
       at Microsoft.VisualStudio.Tools.Applications.Deployment.ClickOnceAddInDeploymentManager.InstallAddIn()
    
    
    ************** Loaded Assemblies **************
    mscorlib
        Assembly Version: 4.0.0.0
        Win32 Version: 4.0.30319.1026 (RTMGDR.030319-1000)
        CodeBase: file:///C:/Windows/Microsoft.NET/Framework/v4.0.30319/mscorlib.dll
    ----------------------------------------
    Microsoft.VisualStudio.Tools.Office.Runtime
        Assembly Version: 10.0.0.0
        Win32 Version: 10.0.60724.0
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/Microsoft.VisualStudio.Tools.Office.Runtime/v4.0_10.0.0.0__b03f5f7f11d50a3a/Microsoft.VisualStudio.Tools.Office.Runtime.dll
    ----------------------------------------
    System.Core
        Assembly Version: 4.0.0.0
        Win32 Version: 4.0.30319.233 built by: RTMGDR
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Core/v4.0_4.0.0.0__b77a5c561934e089/System.Core.dll
    ----------------------------------------
    System
        Assembly Version: 4.0.0.0
        Win32 Version: 4.0.30319.1026 built by: RTMGDR
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System/v4.0_4.0.0.0__b77a5c561934e089/System.dll
    ----------------------------------------
    Microsoft.VisualStudio.Tools.Applications.Hosting
        Assembly Version: 10.0.0.0
        Win32 Version: 10.0.60724.0
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/Microsoft.VisualStudio.Tools.Applications.Hosting/v4.0_10.0.0.0__b03f5f7f11d50a3a/Microsoft.VisualStudio.Tools.Applications.Hosting.dll
    ----------------------------------------
    Microsoft.VisualStudio.Tools.Applications.ServerDocument
        Assembly Version: 10.0.0.0
        Win32 Version: 10.0.60724.0
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/Microsoft.VisualStudio.Tools.Applications.ServerDocument/v4.0_10.0.0.0__b03f5f7f11d50a3a/Microsoft.VisualStudio.Tools.Applications.ServerDocument.dll
    ----------------------------------------
    Microsoft.VisualStudio.Tools.Applications.Runtime
        Assembly Version: 10.0.0.0
        Win32 Version: 10.0.60724.0
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/Microsoft.VisualStudio.Tools.Applications.Runtime/v4.0_10.0.0.0__b03f5f7f11d50a3a/Microsoft.VisualStudio.Tools.Applications.Runtime.dll
    ----------------------------------------
    System.Windows.Forms
        Assembly Version: 4.0.0.0
        Win32 Version: 4.0.30319.1032 built by: RTMGDR
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Windows.Forms/v4.0_4.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
    ----------------------------------------
    System.Drawing
        Assembly Version: 4.0.0.0
        Win32 Version: 4.0.30319.1036 built by: RTMGDR
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Drawing/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
    ----------------------------------------
    System.Xml
        Assembly Version: 4.0.0.0
        Win32 Version: 4.0.30319.1026 built by: RTMGDR
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Xml/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.dll
    ----------------------------------------
    System.Deployment
        Assembly Version: 4.0.0.0
        Win32 Version: 4.0.30319.1039 (RTMGDR.030319-1000)
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Deployment/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Deployment.dll
    ----------------------------------------
    System.Configuration
        Assembly Version: 4.0.0.0
        Win32 Version: 4.0.30319.1015 (RTMGDR.030319-1000)
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Configuration/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
    ----------------------------------------
    System.Security
        Assembly Version: 4.0.0.0
        Win32 Version: 4.0.30319.1031 (RTMGDR.030319-1000)
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Security/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Security.dll
    ----------------------------------------
    System.Xml.Linq
        Assembly Version: 4.0.0.0
        Win32 Version: 4.0.30319.1 built by: RTMRel
        CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Xml.Linq/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.Linq.dll
    ----------------------------------------
    


    Wednesday, October 12, 2016 8:48 AM
  • Hi Bhargav_Gaglani,

    According to your description, when did you get this exception, while installing VSTO or after install VSTO? I sugges that you could create one new VSTO add-in as simple as possible, then try to deploy it.
    Could you reproduce this issue?

    Thanks for your understanding.
    Thursday, October 13, 2016 7:28 AM
  • Hi David,

    I am getting the same exception while VSTO installation. System is not able to install VSTO file. We have tried sample VSTO file as well and we are getting the same exception. I can reproduce it every time.

    Thursday, October 13, 2016 12:39 PM
  • Hi David,

    Any update on this?

    Friday, October 14, 2016 10:39 AM
  • Hi Bhargav_Gaglani,

    Could you provide steps and screenshot about how you install VSTO file and exception?

    Thanks for your understanding.
    Monday, October 17, 2016 9:27 AM
  • Hi David,

    I am opening (double clicking on) VSTO file to install it. Please find attached screenshots for more information.

    Installing (double clicking on) VSTO file

    Error thrown

    Monday, October 17, 2016 12:43 PM
  • Hi David,

    Any update on this? Kindly let me know if you need more details on environment/permissions/etc.

    Wednesday, October 19, 2016 12:05 PM
  • Hi David,

    Do you have any update on this? Or can you please suggest where should I forward my query?

    Wednesday, October 26, 2016 12:09 PM
  • Hi David,

    We just cracked the issue. We found that "administrator" profile was dodgy. We removed particular profile and created new one, and it worked fine!

    Still we are in process to find out what was “dodgy” about the profile.

    Thanks for your help.

    Wednesday, October 26, 2016 12:45 PM
  • Thanks all.
    Wednesday, October 26, 2016 12:46 PM