共用方式為


VirtualDirectoryMappingCollection.Add(String, VirtualDirectoryMapping) 方法

定義

VirtualDirectoryMapping 物件加入至 VirtualDirectoryMappingCollection 執行個體。

public:
 void Add(System::String ^ virtualDirectory, System::Web::Configuration::VirtualDirectoryMapping ^ mapping);
public void Add (string virtualDirectory, System.Web.Configuration.VirtualDirectoryMapping mapping);
member this.Add : string * System.Web.Configuration.VirtualDirectoryMapping -> unit
Public Sub Add (virtualDirectory As String, mapping As VirtualDirectoryMapping)

參數

virtualDirectory
String

String,包含虛擬目錄路徑。

例外狀況

mappingnull

virtualDirectory 已存在於 VirtualDirectoryMappingCollection 中。

適用於