ImportCollection.AddNewImport(String, String) ImportCollection.AddNewImport(String, String) ImportCollection.AddNewImport(String, String) ImportCollection.AddNewImport(String, String) Method

Definition

Allows hosts to programmatically add a new <Import> tag to a project file being manipulated by the host.

public:
 void AddNewImport(System::String ^ projectFile, System::String ^ condition);
public void AddNewImport (string projectFile, string condition);
member this.AddNewImport : string * string -> unit
Public Sub AddNewImport (projectFile As String, condition As String)

Parameters

projectFile
String String String String

A required string representing the name of the project file for the <Import> statement to be added. For example, "myproject.csproj."

condition
String String String String

An optional string indicating whether the element is processed. If condition is true, then the specified <Import> tag is added, if false, it is not.

Applies to