Quantcast
Channel: Visual Studio Integrate forum
Viewing all articles
Browse latest Browse all 4410

Extensibility - Visual Studio Add-in

$
0
0

I have created one add in for add my assemblies dynamically. I have add my assemblies successfully by the following code,

vsproject.References.Add(Assemblyname);


If the target project does not have my assemblies adds successfully. If it have my previous version assemblies ,get the assemblies from the target project (project file) .csproj file. And change the oldversion to newversion and save the project  using this code,

                        
Migrate(_project.FullName, versionnumber);

 _project.Save(_project.FullName);


This migration works sucessfully and target project wants to Reload the project  Then I reloaded the target project it works fine.

If I want to Migration and Additional assemblies add into my target project it throws theproject unavailable exception. If I reload the target project the exception occured in the following code,

VSProject vsproject = (VSProject)_project.Object;

In this code works fine without modifying my project file. But it not works for modify target project file.

Exception details: project unavailable

Inside of exception: The target project object will be shown below lines,

Function evaluation disabled because a previous function evaluation timed out. You must continue execution to reenable function evaluation.

Thanks,

Abbas K


Viewing all articles
Browse latest Browse all 4410

Trending Articles