Click here to Skip to main content
Click here to Skip to main content

Troubleshooting Visual Studio Add-ins, Error Numbers and it's possible solutions

, 23 Sep 2012
Rate this:
Please Sign up or sign in to vote.
Error Number 8013150a, 80131515, 80131522, 80070002, 80004002, 80004005, 80070057, 80131500, 80131018

 


Table Of Contents    

Introduction  

In this article I have tried to cover some of the possible solutions for error numbers that we face with Visual Studio add-in exceptions.  

This errors can happen during development or post installation.

I have put my time and efforts on all of my articles, Please don't forget to mark your votessuggestions and feedback to improve the quality of this and upcoming articles.  

You might be interested in my article on Visual Studio Add-in - Web Search. Please click here to check my other articles.   

Background   

While working with Web Search add-in for Visual Studio I made some notes on add-in error numbers to troubleshoot visual studio add-ins. I thought to share this notes for the developer community to make life easier working with Visual Studio add-ins . 

If you found any other solutions for any of the problems mentioned here, please let me know.

Error Numbers    

Error numbers throws some light on the exception occurred, by using error numbers we can identify the root cause of the problem. 

80131515    

I got this  80131515 error when I tried to run Web Search add-in from a network location. and I made it work after applying the first solution from this post.

How to resolve 80131515 issue.  

This error comes when we run an add-in files from a network location as the dll runs from a network location has less permission.

To resolve this issue we need add loadFromRemoteSources element to the devenv.exe.config file.

Open (with admin rights) the devenv.exe.config file from the below location 

C:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE\devenv.exe.config 

Or  

C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\devenv.exe.config  

and add loadFromRemoteSources element with "true" value, like below,  

<configuration>
   <runtime>
      <loadFromRemoteSources enabled="true"/>
   </runtime>
</configuration>   

Some times the windows tag the downloaded files as "the file comes from a different location" to apply more restrictions on them. The simple solution is to unblock the downloaded zip file or dll file. 

To unblock the file,  just right click on the file (zip/dll/setup), go to 'Properties', then select 'General' tab then click on the 'Unblock' button.  Refer below screen-shot  

If you found any other solution to resolve this issue please let me know.     

80131522 

Visual Studio Add-in Troubleshooting, Error Number 80131522 - Shemeer 

This error comes when the namespace and/or class name of the connect class specified in the .AddIn file doesn't match the actual one declared in the source code.  

If you look at below image the actual Namespace is WebSearch2012

but in the .AddIn the Namespace is mentioned as WebSearch, that's why it caused the error 80131522

If you found any other solution to resolve this issue please let me know. 

80070002  

The 80070002 error is  caused mostly by two reasons, 

  1. The AddIn DLL mentioned in the assembly tag is missing(not valid) or
  2. The AddIn references a DLL that can not be found.   

If you found any other solution to resolve this issue please let me know.    

8013150a 

This error is due to the lack of permission to the AddIn DLL. this happens when we run AddIn from a network location,

The best and simple solution is to Copy the AddIn to a Local folder and add that folder in the folder list of Addins  

  • Go to Tools->Options
  • Select Environment  
  • Go to Add in / Macro security tab 
  • Click Add-> select the local folder where you have copied the AddIn file and AddIn DLL.  

If you found any other solution to resolve this 8013150a issue  please let me know. 

80004002 

The 80004002 error is because of the Assembly is not COM visible. 

I got this error only when I compiled WebSearch with above code. If the System.Runtime.InteropServices.ComVisible is not mentioned then its default by True

Ensure that Connect class is Public and that you have the ComVisible(True) applied at assembly level, or at least at class level  

80004005  

80004005  is due to invalid file specified in <Assembly> tag  

Make sure that the file exits in the specified path mentioned in <Assembly> tag. 

If you found any other solution to resolve this issue issue  please let me know.

80070057 

This error is probably happened because of an Exception occured inside the Add-in code. 

Which Exception? Where?  

Any unhandled error inside OnConnection method of an add-in class will cause the add-in to be removed from Visual Studio.  

The Error Number 80070057 says that an ArgumentException has occurred inside the OnConnection method of Add-in class (mainly Connect class)  

Solution   

Handling the ArgumentException inside the OnConnection method will resolve this issue.    

If you are using any third party add-ins then you should get the latest add-in component (dll) with the fix for this Bug.  

If you found any other solution to resolve this issue please let me know.   

80131018   

 This is due to an unknown file specified in the <Assembly> tag 

80131500   

Visual Studio Add-in Troubleshooting, Error Number 80131500 - Shemeer 

This error is probably happened because of an Exception occured inside the Add-in code.  

Any unhandled error inside OnConnection method of an add-in class will cause the add-in to be removed from Visual Studio.   

The Error Number 80131500 says that an unhandled Exception has occurred inside the OnConnection method of Add-in class (mainly Connect class)  

Solution   

Expect the un-expected errors Smile | <img src=  .   

Handling the Exception inside the OnConnection method will resolve this issue.    

If you are using any third party add-ins then you should get the latest add-in component (dll) with the fix for this Bug. 

If you found any other solution to resolve this issue please let me know.  

References 

Web Search

You might be interested in my article on Visual Studio Add-in - Web Search

Web Search - Visual Studio Add-in , Search (Google, Yahoo, MSDN, Code Project, Stack Overflow and more...) for the selected text/item - Shemeer NS 

Summary        

In this article I have tried to explain some of the common errors with Visual Studio Add-in with multiple solutions, I hope you have enjoyed this article and got some value addition to your knowledge.  

I have put my time and efforts on all of my articles, please don't forget to mark your votessuggestions and feedback to improve the quality of this and upcoming articles.    

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

About the Author

Shemeer NS
Software Developer (Senior)
India India
Technology Specialist | CodeProject MVP | Visual Studio Gallery Contributor | Author | Geek | Netizen | Husband | ChessPlayer
 
Most of my articles are listed on top 5 of the respective 'Best articles of the month' and some of my articles are published on ASP.NET WebSite's Article of the Day section.
 
Check my contributions in Visual Studio Gallery and Code Project
 
Technical Blog: http://www.shemeerns.com
Facebook: http://facebook.com/shemeernsblog
Twitter : http://twitter.com/shemeerns
Google+ : http://google.com/+Shemeernsblog
Follow on   Twitter   Google+

Comments and Discussions

 
Question80131018 PinmemberYogurt17-Sep-13 9:25 
GeneralMy vote of 5 Pinmemberffernandez2324-Sep-12 2:06 
GeneralMy vote of 5 PinmemberKlaus Luedenscheidt23-Sep-12 19:03 
GeneralRe: My vote of 5 PinmemberShemeer NS23-Sep-12 19:54 
GeneralRe: My vote of 5 PinmemberNandita Agrawal513-Mar-13 6:48 
GeneralMy vote of 5 PinmemberForogar23-Sep-12 6:19 
GeneralRe: My vote of 5 PinmemberShemeer NS23-Sep-12 6:51 
QuestionHey PinmemberZac Greve23-Sep-12 5:51 
AnswerRe: Hey PinmemberShemeer NS23-Sep-12 6:49 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

| Advertise | Privacy | Mobile
Web01 | 2.8.140721.1 | Last Updated 23 Sep 2012
Article Copyright 2012 by Shemeer NS
Everything else Copyright © CodeProject, 1999-2014
Terms of Service
Layout: fixed | fluid