10 instantiations of ProjectCollection
dotnet-aot (1)
parent\dotnet\CliCompletion.cs (1)
73new ProjectCollection(),
Microsoft.Build (3)
Construction\Solution\SolutionProjectGenerator.cs (1)
1051new ProjectCollection(),
Definition\ProjectCollection.cs (2)
314/// This constructor disables target output logging, so TerminalLogger and other loggers may not work well. Prefer <see cref="ProjectCollection(IDictionary{string, string}, IEnumerable{ILogger}, IEnumerable{ForwardingLoggerRecord}, ToolsetDefinitionLocations, int, bool, bool, bool, bool, bool)"/> instead to control this behavior. 528var local = new ProjectCollection(null, null, ToolsetDefinitionLocations.Default,
Microsoft.CodeAnalysis.Workspaces.MSBuild.BuildHost (1)
Build\ProjectBuildManager.cs (1)
98_projectCollection = new MSB.Evaluation.ProjectCollection(allProperties, loggers: [], MSB.Evaluation.ToolsetDefinitionLocations.Default);
Microsoft.DotNet.Arcade.Sdk (1)
src\InstallDotNetCore.cs (1)
107var proj = Project.FromFile(versionsPropsPath, new Microsoft.Build.Definition.ProjectOptions() { ProjectCollection = new ProjectCollection() });
Microsoft.DotNet.HotReload.Watch (1)
Build\ProjectGraphFactory.cs (1)
31private readonly ProjectCollection _collection = new(
MSBuild (2)
XMake.cs (2)
1119using (ProjectCollection collection = new(globalProperties, loggers, ToolsetDefinitionLocations.Default)) 1783projectCollection = new ProjectCollection(
NuGet.Build.Tasks.Console (1)
MSBuildStaticGraphRestore.cs (1)
1288using var projectCollection = new ProjectCollection(
184 references to ProjectCollection
dotnet-aot (6)
parent\dotnet\MsbuildProject.cs (6)
38private readonly ProjectCollection _projects; 45private MsbuildProject(ProjectCollection projects, ProjectRootElement project, bool interactive) 53public static MsbuildProject FromFileOrDirectory(ProjectCollection projects, string fileOrDirectory, bool interactive) 65public static MsbuildProject FromFile(ProjectCollection projects, string projectPath, bool interactive) 81public static MsbuildProject FromDirectory(ProjectCollection projects, string projectDirectory, bool interactive) 286private static ProjectRootElement TryOpenProject(ProjectCollection projects, string filename)
dotnet-openapi (1)
Commands\BaseCommand.cs (1)
127var project = ProjectCollection.GlobalProjectCollection.LoadProject(
Microsoft.Build (127)
BackEnd\BuildManager\BuildManager.cs (5)
1377_buildTelemetry.BuildEngineVersion = ProjectCollection.Version; 1378_buildTelemetry.BuildEngineDisplayVersion = ProjectCollection.DisplayVersion; 1512ProjectCollection.Version?.ToString(), 1534BuildEngineVersion = ProjectCollection.Version?.ToString(), 2454ProjectCollection.GlobalProjectCollection,
BackEnd\BuildManager\BuildParameters.cs (1)
257public BuildParameters(ProjectCollection projectCollection)
BackEnd\Components\SdkResolution\SdkResolverService.cs (1)
334SdkResolverContext context = new SdkResolverContext(buildEngineLogger, projectPath, solutionPath, ProjectCollection.Version, interactive, isRunningInVisualStudio)
BackEnd\Node\OutOfProcNode.cs (2)
776ProjectCollection.GlobalProjectCollection.RemoveAllToolsets(); 780ProjectCollection.GlobalProjectCollection.AddToolset(toolSet);
Construction\ProjectRootElement.cs (22)
403public string EscapedFullPath => _escapedFullPath ?? (_escapedFullPath = ProjectCollection.Escape(FullPath)); 747return Create(ProjectCollection.GlobalProjectCollection, Project.DefaultNewProjectTemplateOptions); 756return Create(ProjectCollection.GlobalProjectCollection, projectFileOptions); 763public static ProjectRootElement Create(ProjectCollection projectCollection) 769/// Initialize an in-memory, empty ProjectRootElement instance that can be saved later using the specified <see cref="ProjectCollection"/> and <see cref="NewProjectFileOptions"/>. 771public static ProjectRootElement Create(ProjectCollection projectCollection, NewProjectFileOptions projectFileOptions) 784return Create(path, ProjectCollection.GlobalProjectCollection, Project.DefaultNewProjectTemplateOptions); 793return Create(path, ProjectCollection.GlobalProjectCollection, newProjectFileOptions); 800public static ProjectRootElement Create(string path, ProjectCollection projectCollection) 809public static ProjectRootElement Create(string path, ProjectCollection projectCollection, NewProjectFileOptions newProjectFileOptions) 829return Create(xmlReader, ProjectCollection.GlobalProjectCollection, preserveFormatting: false); 837public static ProjectRootElement Create(XmlReader xmlReader, ProjectCollection projectCollection) 847public static ProjectRootElement Create(XmlReader xmlReader, ProjectCollection projectCollection, bool preserveFormatting) 862return Open(path, ProjectCollection.GlobalProjectCollection); 870public static ProjectRootElement Open(string path, ProjectCollection projectCollection) 880public static ProjectRootElement Open(string path, ProjectCollection projectCollection, bool? preserveFormatting) 904return TryOpen(path, ProjectCollection.GlobalProjectCollection); 912/// <param name="projectCollection">The <see cref="ProjectCollection"/> to load the project into.</param> 918public static ProjectRootElement TryOpen(string path, ProjectCollection projectCollection) 928/// <param name="projectCollection">The <see cref="ProjectCollection"/> to load the project into.</param> 937public static ProjectRootElement TryOpen(string path, ProjectCollection projectCollection, bool? preserveFormatting) 1783return new ProjectRootElement(document, ProjectCollection.GlobalProjectCollection.ProjectRootElementCache);
Construction\Solution\SolutionProjectGenerator.cs (1)
27using ProjectCollection = Microsoft.Build.Evaluation.ProjectCollection;
Definition\Project.cs (26)
104internal Project(ProjectCollection projectCollection, ProjectLink link) 129: this(ProjectRootElement.Create(ProjectCollection.GlobalProjectCollection, newProjectFileOptions)) 138public Project(ProjectCollection projectCollection) 148public Project(ProjectCollection projectCollection, NewProjectFileOptions newProjectFileOptions) 161public Project(IDictionary<string, string> globalProperties, string toolsVersion, ProjectCollection projectCollection) 175public Project(IDictionary<string, string> globalProperties, string toolsVersion, ProjectCollection projectCollection, NewProjectFileOptions newProjectFileOptions) 204: this(xml, globalProperties, toolsVersion, ProjectCollection.GlobalProjectCollection) 219public Project(ProjectRootElement xml, IDictionary<string, string> globalProperties, string toolsVersion, ProjectCollection projectCollection) 236public Project(ProjectRootElement xml, IDictionary<string, string> globalProperties, string toolsVersion, ProjectCollection projectCollection, ProjectLoadSettings loadSettings) 254public Project(ProjectRootElement xml, IDictionary<string, string> globalProperties, string toolsVersion, string subToolsetVersion, ProjectCollection projectCollection, ProjectLoadSettings loadSettings) 259private Project(ProjectRootElement xml, IDictionary<string, string> globalProperties, string toolsVersion, string subToolsetVersion, ProjectCollection projectCollection, ProjectLoadSettings loadSettings, 298: this(xmlReader, globalProperties, toolsVersion, ProjectCollection.GlobalProjectCollection) 313public Project(XmlReader xmlReader, IDictionary<string, string> globalProperties, string toolsVersion, ProjectCollection projectCollection) 330public Project(XmlReader xmlReader, IDictionary<string, string> globalProperties, string toolsVersion, ProjectCollection projectCollection, ProjectLoadSettings loadSettings) 348public Project(XmlReader xmlReader, IDictionary<string, string> globalProperties, string toolsVersion, string subToolsetVersion, ProjectCollection projectCollection, ProjectLoadSettings loadSettings) 353private Project(XmlReader xmlReader, IDictionary<string, string> globalProperties, string toolsVersion, string subToolsetVersion, ProjectCollection projectCollection, ProjectLoadSettings loadSettings, 391: this(projectFile, globalProperties, toolsVersion, ProjectCollection.GlobalProjectCollection) 407public Project(string projectFile, IDictionary<string, string> globalProperties, string toolsVersion, ProjectCollection projectCollection) 425public Project(string projectFile, IDictionary<string, string> globalProperties, string toolsVersion, ProjectCollection projectCollection, ProjectLoadSettings loadSettings) 444public Project(string projectFile, IDictionary<string, string> globalProperties, string toolsVersion, string subToolsetVersion, ProjectCollection projectCollection, ProjectLoadSettings loadSettings) 449private Project(string projectFile, IDictionary<string, string> globalProperties, string toolsVersion, string subToolsetVersion, ProjectCollection projectCollection, ProjectLoadSettings loadSettings, 496options.ProjectCollection ?? ProjectCollection.GlobalProjectCollection, 516options.ProjectCollection ?? ProjectCollection.GlobalProjectCollection, 536options.ProjectCollection ?? ProjectCollection.GlobalProjectCollection, 588public ProjectCollection ProjectCollection { get; } 1997private ProjectCollection ProjectCollection => Owner.ProjectCollection;
Definition\ProjectCollection.cs (4)
102private static ProjectCollection s_globalProjectCollection; 520public static ProjectCollection GlobalProjectCollection 528var local = new ProjectCollection(null, null, ToolsetDefinitionLocations.Default, 561string fileVersion = typeof(ProjectCollection).Assembly
Definition\ProjectCollectionChangedEventArgs.cs (9)
9/// Properties or other mutable state associated with a <see cref="ProjectCollection"/>. 14/// The <see cref="ProjectCollection.DefaultToolsVersion"/> property changed. 34/// The <see cref="ProjectCollection.IsBuildEnabled"/> property changed. 39/// The <see cref="ProjectCollection.OnlyLogCriticalEvents"/> property changed. 44/// The <see cref="ProjectCollection.HostServices"/> property changed. 49/// The <see cref="ProjectCollection.DisableMarkDirty"/> property changed. 54/// The <see cref="ProjectCollection.SkipEvaluation"/> property changed. 61/// Event arguments for the <see cref="ProjectCollection.ProjectCollectionChanged"/> event. 74/// Gets the nature of the change made to the <see cref="ProjectCollection"/>.
Definition\ProjectOptions.cs (2)
35/// The <see cref="ProjectCollection"/> the project is added to. Default is <see cref="ProjectCollection.GlobalProjectCollection"/>. 37public ProjectCollection ProjectCollection { get; set; }
Definition\Toolset.cs (4)
159public Toolset(string toolsVersion, string toolsPath, ProjectCollection projectCollection, string msbuildOverrideTasksPath) 175public Toolset(string toolsVersion, string toolsPath, IDictionary<string, string> buildProperties, ProjectCollection projectCollection, string msbuildOverrideTasksPath) 192public Toolset(string toolsVersion, string toolsPath, IDictionary<string, string> buildProperties, ProjectCollection projectCollection, IDictionary<string, SubToolset> subToolsets, string msbuildOverrideTasksPath) 293internal Toolset(string toolsVersion, string toolsPath, PropertyDictionary<ProjectPropertyInstance> buildProperties, ProjectCollection projectCollection, DirectoryGetFiles getFiles, LoadXmlFromPath loadXmlFromPath, string msbuildOverrideTasksPath, DirectoryExists directoryExists)
Evaluation\Evaluator.cs (2)
1282private static readonly string CachedFileVersion = ProjectCollection.Version.ToString(); 1300SetBuiltInProperty(ReservedPropertyNames.SemanticVersion, ProjectCollection.DisplayVersion);
Evaluation\ProjectChangedEventArgs.cs (1)
9/// Event arguments for the <see cref="ProjectCollection.ProjectChanged"/> event.
Evaluation\ProjectXmlChangedEventArgs.cs (1)
13/// Event arguments for the <see cref="ProjectCollection.ProjectXmlChanged"/> event.
Graph\GraphBuilder.cs (3)
49private readonly ProjectCollection _projectCollection; 68ProjectCollection projectCollection, 654ProjectCollection projectCollection)
Graph\ProjectGraph.cs (19)
39/// <param name="projectCollection">The <see cref="ProjectCollection" /> context for parsing.</param> 59ProjectCollection projectCollection); 117: this(new ProjectGraphEntryPoint(entryProjectFile).AsEnumerable(), ProjectCollection.GlobalProjectCollection, null) 130: this(ProjectGraphEntryPoint.CreateEnumerable(entryProjectFiles), ProjectCollection.GlobalProjectCollection, null) 146public ProjectGraph(string entryProjectFile, ProjectCollection projectCollection) 163public ProjectGraph(IEnumerable<string> entryProjectFiles, ProjectCollection projectCollection) 189public ProjectGraph(string entryProjectFile, ProjectCollection projectCollection, ProjectInstanceFactoryFunc projectInstanceFactory) 207: this(new ProjectGraphEntryPoint(entryProjectFile, globalProperties).AsEnumerable(), ProjectCollection.GlobalProjectCollection, null) 224: this(ProjectGraphEntryPoint.CreateEnumerable(entryProjectFiles, globalProperties), ProjectCollection.GlobalProjectCollection, null) 244public ProjectGraph(string entryProjectFile, IDictionary<string, string> globalProperties, ProjectCollection projectCollection) 265public ProjectGraph(IEnumerable<string> entryProjectFiles, IDictionary<string, string> globalProperties, ProjectCollection projectCollection) 278: this(entryPoint.AsEnumerable(), ProjectCollection.GlobalProjectCollection, null) 290: this(entryPoints, ProjectCollection.GlobalProjectCollection, null) 305public ProjectGraph(ProjectGraphEntryPoint entryPoint, ProjectCollection projectCollection) 336ProjectCollection projectCollection, 376ProjectCollection projectCollection, 420ProjectCollection projectCollection, 972ProjectCollection projectCollection) 986ProjectCollection projectCollection,
Graph\ProjectGraphOptions.cs (3)
46/// The <see cref="ProjectCollection" /> to load projects into when constructing the graph. Defaults to <see cref="ProjectCollection.GlobalProjectCollection" />. 48public ProjectCollection ProjectCollection { get; init; } = ProjectCollection.GlobalProjectCollection;
Graph\ProjectInterpretation.cs (1)
75public IEnumerable<ReferenceInfo> GetReferences(ProjectGraphNode projectGraphNode, ProjectCollection projectCollection, ProjectGraph.ProjectInstanceFactoryFunc projectInstanceFactory, ProjectGraphMode graphMode)
Instance\ProjectInstance.cs (13)
234: this(projectFile, globalProperties, toolsVersion, ProjectCollection.GlobalProjectCollection) 250public ProjectInstance(string projectFile, IDictionary<string, string> globalProperties, string toolsVersion, ProjectCollection projectCollection) 268public ProjectInstance(string projectFile, IDictionary<string, string> globalProperties, string toolsVersion, string subToolsetVersion, ProjectCollection projectCollection) 285internal ProjectInstance(string projectFile, IDictionary<string, string> globalProperties, string toolsVersion, string subToolsetVersion, ProjectCollection projectCollection, EvaluationContext context, bool interactive = false) 309private ProjectInstance(string projectFile, IDictionary<string, string> globalProperties, string toolsVersion, string subToolsetVersion, ProjectCollection projectCollection, 341: this(xml, null, null, ProjectCollection.GlobalProjectCollection) 357public ProjectInstance(ProjectRootElement xml, IDictionary<string, string> globalProperties, string toolsVersion, ProjectCollection projectCollection) 376public ProjectInstance(ProjectRootElement xml, IDictionary<string, string> globalProperties, string toolsVersion, string subToolsetVersion, ProjectCollection projectCollection) 553private ProjectInstance(ProjectRootElement xml, IDictionary<string, string> globalProperties, string toolsVersion, string subToolsetVersion, ProjectCollection projectCollection, 630internal ProjectInstance(ProjectRootElement xml, IDictionary<string, string> globalProperties, string toolsVersion, int visualStudioVersionFromSolution, ProjectCollection projectCollection, ISdkResolverService sdkResolverService, int submissionId) 645internal ProjectInstance(ProjectRootElement xml, IDictionary<string, string> globalProperties, string toolsVersion, ILoggingService loggingService, int visualStudioVersionFromSolution, ProjectCollection projectCollection, ISdkResolverService sdkResolverService, int submissionId) 936options.ProjectCollection ?? ProjectCollection.GlobalProjectCollection, 956options.ProjectCollection ?? ProjectCollection.GlobalProjectCollection,
Logging\ReusableLogger.cs (1)
16/// <see cref="Evaluation.ProjectCollection"/>/<see cref="Evaluation.Project"/> _and_
ObjectModelRemoting\ExternalProjectsProvider.cs (2)
27public virtual void Disconnected(ProjectCollection collection) { } 36public static void SetExternalProjectsProvider(ProjectCollection collection, ExternalProjectsProvider link)
ObjectModelRemoting\LinkedObjectFactory.cs (4)
33private LinkedObjectsFactory(ProjectCollection collection) 42public static LinkedObjectsFactory Get(ProjectCollection collection) 68public ProjectCollection Collection { get; } 73public static IReadOnlyCollection<Project> GetLocalProjects(ProjectCollection collection, string projectFile = null)
Microsoft.Build.Tasks.Git (7)
GitOperations.cs (7)
280var item = new TaskItem(Evaluation.ProjectCollection.Escape(repoRoot)); 282item.SetMetadata(Names.SourceRoot.ScmRepositoryUrl, Evaluation.ProjectCollection.Escape(repositoryUrl)); 284item.SetMetadata(Names.SourceRoot.BranchName, Evaluation.ProjectCollection.Escape(branchName)); 342var item = new TaskItem(Evaluation.ProjectCollection.Escape(submodule.WorkingDirectoryFullPath.EndWithSeparator())); 344item.SetMetadata(Names.SourceRoot.ScmRepositoryUrl, Evaluation.ProjectCollection.Escape(submoduleUri.AbsoluteUri)); 346item.SetMetadata(Names.SourceRoot.ContainingRoot, Evaluation.ProjectCollection.Escape(repoRoot)); 347item.SetMetadata(Names.SourceRoot.NestedRoot, Evaluation.ProjectCollection.Escape(submodule.WorkingDirectoryRelativePath.EndWithSeparator('/')));
Microsoft.CodeAnalysis.Workspaces.MSBuild.BuildHost (1)
Build\ProjectBuildManager.cs (1)
62private readonly MSB.Evaluation.ProjectCollection _projectCollection;
Microsoft.DotNet.Cli.Utils (1)
MSBuildForwardingAppWithoutLogging.cs (1)
36get => Build.Evaluation.ProjectCollection.DisplayVersion;
Microsoft.DotNet.HotReload.Watch (6)
Build\LoadedProjectGraph.cs (2)
12internal sealed class LoadedProjectGraph(ProjectGraph graph, ProjectCollection collection, ILogger logger, GlobalOptions globalOptions, EnvironmentOptions environmentOptions) 30public ProjectCollection ProjectCollection => collection;
Build\ProjectBuildManager.cs (2)
11internal sealed class ProjectBuildManager(ProjectCollection collection, BuildReporter reporter) 20public readonly ProjectCollection Collection = collection;
Build\ProjectGraphFactory.cs (2)
31private readonly ProjectCollection _collection = new( 115private ProjectInstance CreateProjectInstance(string projectPath, Dictionary<string, string> globalProperties, ProjectCollection projectCollection, string virtualProjectTargetFramework, ILogger logger)
Microsoft.DotNet.ProjectTools (4)
BuildService.cs (4)
33private static readonly ConditionalWeakTable<Microsoft.Build.Evaluation.ProjectCollection, IProjectCollection> s_projectCollections = new(); 35extension(Microsoft.Build.Evaluation.ProjectCollection projectCollection) 68sealed file class ProjectCollection(Microsoft.Build.Evaluation.ProjectCollection inner) : IProjectCollection 80public Microsoft.Build.Evaluation.ProjectCollection Inner => inner;
Microsoft.NET.Build.Tasks (1)
ResolvePackageAssets.cs (1)
1922_writer.Write(ProjectCollection.Escape(itemSpec));
Microsoft.NET.Sdk.Publish.Tasks (1)
Tasks\GenerateEFSQLScripts.cs (1)
60string connectionStringEscaped = ProjectCollection.Escape(dbContext.GetMetadata("Value"));
Microsoft.SourceLink.AzureDevOpsServer.Git (1)
src\sourcelink\src\Common\GitProvider\TranslateRepositoryUrlGitTask.cs (1)
110sourceRoot.SetMetadata(Names.SourceRoot.ScmRepositoryUrl, Evaluation.ProjectCollection.Escape(translatedUrl));
Microsoft.SourceLink.AzureRepos.Git (1)
src\sourcelink\src\Common\GitProvider\TranslateRepositoryUrlGitTask.cs (1)
110sourceRoot.SetMetadata(Names.SourceRoot.ScmRepositoryUrl, Evaluation.ProjectCollection.Escape(translatedUrl));
Microsoft.SourceLink.Bitbucket.Git (1)
src\sourcelink\src\Common\GitProvider\TranslateRepositoryUrlGitTask.cs (1)
110sourceRoot.SetMetadata(Names.SourceRoot.ScmRepositoryUrl, Evaluation.ProjectCollection.Escape(translatedUrl));
Microsoft.SourceLink.Gitea (1)
src\sourcelink\src\Common\GitProvider\TranslateRepositoryUrlGitTask.cs (1)
110sourceRoot.SetMetadata(Names.SourceRoot.ScmRepositoryUrl, Evaluation.ProjectCollection.Escape(translatedUrl));
Microsoft.SourceLink.Gitee (1)
src\sourcelink\src\Common\GitProvider\TranslateRepositoryUrlGitTask.cs (1)
110sourceRoot.SetMetadata(Names.SourceRoot.ScmRepositoryUrl, Evaluation.ProjectCollection.Escape(translatedUrl));
Microsoft.SourceLink.GitHub (1)
src\sourcelink\src\Common\GitProvider\TranslateRepositoryUrlGitTask.cs (1)
110sourceRoot.SetMetadata(Names.SourceRoot.ScmRepositoryUrl, Evaluation.ProjectCollection.Escape(translatedUrl));
Microsoft.SourceLink.GitLab (1)
src\sourcelink\src\Common\GitProvider\TranslateRepositoryUrlGitTask.cs (1)
110sourceRoot.SetMetadata(Names.SourceRoot.ScmRepositoryUrl, Evaluation.ProjectCollection.Escape(translatedUrl));
Microsoft.SourceLink.GitWeb (1)
src\sourcelink\src\Common\GitProvider\TranslateRepositoryUrlGitTask.cs (1)
110sourceRoot.SetMetadata(Names.SourceRoot.ScmRepositoryUrl, Evaluation.ProjectCollection.Escape(translatedUrl));
MSBuild (9)
XMake.cs (9)
1119using (ProjectCollection collection = new(globalProperties, loggers, ToolsetDefinitionLocations.Default)) 1445ProjectCollection.Version?.ToString(), 1703ProjectCollection projectCollection = null; 2114private static bool PrintTargets(string projectFile, string toolsVersion, Dictionary<string, string> globalProperties, TextWriter targetsWriter, ProjectCollection projectCollection) 2163ProjectCollection.DisplayVersion), 4228Assembly engineAssembly = typeof(ProjectCollection).Assembly; 4287Assembly engineAssembly = typeof(ProjectCollection).Assembly; 4748Console.WriteLine(ResourceUtilities.FormatResourceStringStripCodeAndKeyword("MSBuildVersionMessage", ProjectCollection.DisplayVersion, NativeMethods.FrameworkName)); 4803Console.WriteLine(ProjectCollection.Version.ToString());
NuGet.Build.Tasks.Console (1)
MSBuildStaticGraphRestore.cs (1)
1288using var projectCollection = new ProjectCollection(
NuGet.CommandLine.XPlat (11)
Commands\Why\WhyCommandRunner.cs (1)
151ProjectCollection.GlobalProjectCollection.UnloadProject(project);
IVirtualProjectBuilder.cs (1)
32ProjectRootElement CreateProjectRootElement(string entryPointFilePath, ProjectCollection projectCollection);
Utility\MSBuildAPIUtility.cs (9)
179ProjectCollection.GlobalProjectCollection.UnloadProject(project.Project); 190ProjectCollection.GlobalProjectCollection.UnloadProject(project.Project); 277ProjectCollection.GlobalProjectCollection.UnloadProject(project); 296ProjectCollection.GlobalProjectCollection.UnloadProject(project.Project); 316ProjectCollection.GlobalProjectCollection.UnloadProject(project.Project); 937var newProject = new ProjectInstance(project.Xml, globalProperties, null, ProjectCollection.GlobalProjectCollection); 1002ProjectCollection.GlobalProjectCollection.UnloadProject(projectPerFramework); 1071var element = VirtualProjectBuilder.CreateProjectRootElement(fullPath, ProjectCollection.GlobalProjectCollection); 1077return (ProjectRootElement.Open(filename, ProjectCollection.GlobalProjectCollection, preserveFormatting: true), false);