none
After applying VS 2010 SP1, Appbase is set to IDE folder RRS feed

  • Question

  • This is a C# solution targeting .Net Framework 4.0.  It is also a Word 2010 add-in, so you may want this under the Office forum.

    The  solution built fine until I applied SP1 to VS 2010.  After that, I see the error below.  It looks as though VS is searching for my files in C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/, rather than in my project folder.  Is there a way to get Apppath set to the project folder?

    Thanks,

    Art

     

    Error 102 The "FindRibbons" task failed unexpectedly.
    System.IO.FileNotFoundException: Could not load file or assembly 'xWordDesigner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified.
    File name: 'xWordDesigner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null'
       at System.Reflection.RuntimeAssembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
       at System.Reflection.RuntimeAssembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
       at System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection, Boolean suppressSecurityChecks)
       at System.Reflection.RuntimeAssembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection)
       at System.Reflection.Assembly.Load(String assemblyString)
       at System.UnitySerializationHolder.GetRealObject(StreamingContext context)

       at Microsoft.Build.Framework.ITask.Execute()
       at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute()
       at Microsoft.Build.BackEnd.TaskBuilder.ExecuteInstantiatedTask(ITaskExecutionHost taskExecutionHost, TaskLoggingContext taskLoggingContext, TaskHost taskHost, ItemBucket bucket, TaskExecutionMode howToExecuteTask, Boolean& taskResult)

    === Pre-bind state information ===
    LOG: User = CORP\gardna
    LOG: DisplayName = xWordDesigner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
     (Fully-specified)
    LOG: Appbase = file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/
    LOG: Initial PrivatePath = NULL
    Calling assembly : (Unknown).
    ===
    LOG: This bind starts in default load context.
    LOG: Using application configuration file: C:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE\devenv.exe.Config
    LOG: Using host configuration file:
    LOG: Using machine configuration file from C:\Windows\Microsoft.NET\Framework\v4.0.30319\config\machine.config.
    LOG: Policy not being applied to reference at this time (private, custom, partial, or location-based assembly bind).
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/xWordDesigner.DLL.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/xWordDesigner/xWordDesigner.DLL.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/PublicAssemblies/xWordDesigner.DLL.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/PublicAssemblies/xWordDesigner/xWordDesigner.DLL.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/xWordDesigner.DLL.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/xWordDesigner/xWordDesigner.DLL.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Microsoft/TemplateProviders/xWordDesigner.DLL.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Microsoft/TemplateProviders/xWordDesigner/xWordDesigner.DLL.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/DataCollectors/xWordDesigner.DLL.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/DataCollectors/xWordDesigner/xWordDesigner.DLL.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/DataCollectors/x86/xWordDesigner.DLL.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/DataCollectors/x86/xWordDesigner/xWordDesigner.DLL.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Microsoft/Editor/xWordDesigner.DLL.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Microsoft/Editor/xWordDesigner/xWordDesigner.DLL.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Platform/Debugger/xWordDesigner.DLL.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Platform/Debugger/xWordDesigner/xWordDesigner.DLL.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/xWordDesigner.EXE.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/xWordDesigner/xWordDesigner.EXE.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/PublicAssemblies/xWordDesigner.EXE.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/PublicAssemblies/xWordDesigner/xWordDesigner.EXE.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/xWordDesigner.EXE.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/xWordDesigner/xWordDesigner.EXE.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Microsoft/TemplateProviders/xWordDesigner.EXE.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Microsoft/TemplateProviders/xWordDesigner/xWordDesigner.EXE.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/DataCollectors/xWordDesigner.EXE.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/DataCollectors/xWordDesigner/xWordDesigner.EXE.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/DataCollectors/x86/xWordDesigner.EXE.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/DataCollectors/x86/xWordDesigner/xWordDesigner.EXE.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Microsoft/Editor/xWordDesigner.EXE.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Microsoft/Editor/xWordDesigner/xWordDesigner.EXE.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Platform/Debugger/xWordDesigner.EXE.
    LOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Platform/Debugger/xWordDesigner/xWordDesigner.EXE.
     xWordDesigner


    Arthur Gardner

    Thursday, May 9, 2013 3:17 PM

Answers

  • Just for the record, I ended up solving this issue by applying the 5th (I think) suggestion found via that link, which have accidentally preserved in an email.  It sounds random and scary, but it worked for me:

    Posted by Dan9298 on 9/20/2011 at 9:02 AM

    This worked for my solution, but use at your own risk: 1. Open the following file in an xml editor (make a backup first): "C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v10.0\OfficeTools\Microsoft.VisualStudio.Tools.Office.targets" 2. Remove the following section: <FindRibbons          AssemblyName="$(AbsolutePathToCustomization)"          TargetFramework="$(TargetFrameworkVersion)"         >          <Output TaskParameter="RibbonTypes" ItemName="RibbonTypesCollection"/>         </FindRibbons> 3. Replace all occurrences of "@(RibbonTypesCollection)" with "" 4. Save the file and restart visual studio



    Arthur Gardner

    Thursday, August 7, 2014 1:18 PM

All replies

  • Hi Arthur Gardner,

    Thanks for your post.

    It appears that this is not an issue with Visual Studio, but a problem with your project.

    Does this solution works for your http://connect.microsoft.com/VisualStudio/feedback/details/651634/the-findribbons-task-failed-unexpectedly

    regards,


    Barry Wang
    MSDN Community Support | Feedback to us
    Develop and promote your apps in Windows Store
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Friday, May 10, 2013 6:10 AM
  • Thanks, Barry.  I studied that document before filing my issue, but could not see the relevance to my case.

    Can you tell me what determines the Apppath value that appears in the following?

    LOG: Appbase = file:///C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/

    Art


    Arthur Gardner

    Friday, May 10, 2013 1:17 PM
  • This issue could happen if you build by devenv though command line. Is that the case?

    To solve the assembly binding issue, you can install the xWordDesigner.dll to GAC

    gacutil /i xWordDesigner


    Forrest Guo | MSDN Community Support | Feedback to manager

    Tuesday, May 14, 2013 1:46 AM
    Moderator
  • show us screenshot of registry entries for your add-in (Manifest being to most important entry)

    Tuesday, May 14, 2013 6:16 AM
  • Thank you.

    I'm building from the Visual Studio UI.

    Holding off on the GAC idea while I look at the registry.

    I found no registry entries at all under HKEY_CURRENT_USER\Software\Microsoft\Office\Word\Addins nor under HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\Word\Addins.

    To have something to compare with, I created a second, new Word add-in project, and looked at the resulting registry entries.  Its Manifest entry pointed to a file like ProjectName.vsto, and I don't see such a file in my real project.

    I restored xWordDesigner.vsto from a backup (to \bin\Debug), cleaned & rebuilt, same error.


    Arthur Gardner

    Tuesday, May 14, 2013 4:35 PM
  • gacutil says it won't install the project unless I give it a strong name.  But that would be a team decision.  The whole solution, including project files, is under source control, and the other devs, who are still using 10.0.30319.1 RTM, can build it just fine.

    Art


    Arthur Gardner

    Tuesday, May 14, 2013 10:05 PM
  • So I misunderstood your case. xWordDesigner.dll is the output of addin project, it's not the project reference.

    You didn't find the addin entry as the build fails.

    It is necessary to collect the build log and analyze it. Can you share the log?

    thanks.


    Forrest Guo | MSDN Community Support | Feedback to manager

    Wednesday, May 15, 2013 2:04 AM
    Moderator
  • The detailed build output is too large to paste.  I have uploaded it as buildlog.txt to a temporary FTP site.  Please let me know it you cannot access it.

    ---URL---

    ftp://gasvenfok:flovOmph8@ftp.docscience.com

        OR

    ---Manual Connect Info (FTP client of choice)---

    Username: gasvenfok

    Password: flovOmph8

      Server: ftp.docscience.com

    -----------------

    Automatic FTP account removal on May 22, 2013 at 06:57


    Arthur Gardner

    Wednesday, May 15, 2013 2:04 PM
  • No thoughts?  Do I need to open a support incident?

    Arthur Gardner

    Tuesday, May 21, 2013 1:33 PM
  • It appears that this is not an issue with Visual Studio, but a problem with your project.

    Does this solution works for your http://connect.microsoft.com/VisualStudio/feedback/details/651634/the-findribbons-task-failed-unexpectedly

    regards,


    Barry Wang

    I am currently investigating a similar issue but the link on your comment doesn't work any more. Would you please update the link or summarise the resolution here? Thank you.
    Thursday, August 7, 2014 12:14 AM
  • Just for the record, I ended up solving this issue by applying the 5th (I think) suggestion found via that link, which have accidentally preserved in an email.  It sounds random and scary, but it worked for me:

    Posted by Dan9298 on 9/20/2011 at 9:02 AM

    This worked for my solution, but use at your own risk: 1. Open the following file in an xml editor (make a backup first): "C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v10.0\OfficeTools\Microsoft.VisualStudio.Tools.Office.targets" 2. Remove the following section: <FindRibbons          AssemblyName="$(AbsolutePathToCustomization)"          TargetFramework="$(TargetFrameworkVersion)"         >          <Output TaskParameter="RibbonTypes" ItemName="RibbonTypesCollection"/>         </FindRibbons> 3. Replace all occurrences of "@(RibbonTypesCollection)" with "" 4. Save the file and restart visual studio



    Arthur Gardner

    Thursday, August 7, 2014 1:18 PM