Uri.UriSchemeFtp 字段

定义

指定通过文件传输协议 (FTP) 访问 URI。 此字段为只读。

public: static initonly System::String ^ UriSchemeFtp;
public static readonly string UriSchemeFtp;
 staticval mutable UriSchemeFtp : string
Public Shared ReadOnly UriSchemeFtp As String 

字段值

示例

以下示例创建 一个 Uri 实例,并确定方案是否为 UriSchemeFtp

Uri^ address7 = gcnew Uri( "ftp://contoso/files/testfile.txt" );
if ( address7->Scheme == Uri::UriSchemeFtp )
{
   Console::WriteLine( "Uri is Ftp protocol" );
}
Uri address7 = new Uri("ftp://contoso/files/testfile.txt");
if (address7.Scheme == Uri.UriSchemeFtp)
    Console.WriteLine("Uri is Ftp protocol");
let address7 = Uri "ftp://contoso/files/testfile.txt"
if address7.Scheme = Uri.UriSchemeFtp then
    printfn "Uri is Ftp protocol"
Dim address7 As New Uri("ftp://contoso/files/testfile.txt")
If address7.Scheme = Uri.UriSchemeFtp Then
    Console.WriteLine("Uri is Ftp protocol")
End If

适用于