C# Uri UriSchemeFtp
Description
Uri UriSchemeFtp
specifies that the URI is accessed through
the File Transfer Protocol (FTP). This field is read-only.
Syntax
Uri.UriSchemeFtp
has the following syntax.
public static readonly string UriSchemeFtp
Example
The following example creates a Uri instance and determines whether the scheme is UriSchemeFtp.
//from ww w . ja v a 2s .c o m
using System;
public class MainClass{
public static void Main(String[] argv){
Uri address7 = new Uri("ftp://java2s.com/files/testfile.txt");
if (address7.Scheme == Uri.UriSchemeFtp)
Console.WriteLine("Uri is Ftp protocol");
}
}
The code above generates the following result.