NET FTP Library
WildcardToRegex Method
Example 






KellermanSoftware.NetFtpLibrary Namespace > FTP Class : WildcardToRegex Method
Translate a wildcard pattern to a regex string
Syntax
'Declaration
 
Public Function WildcardToRegex( _
   ByVal wildcard As System.String _
) As System.String
'Usage
 
Dim instance As FTP
Dim wildcard As System.String
Dim value As System.String
 
value = instance.WildcardToRegex(wildcard)
public System.string WildcardToRegex( 
   System.string wildcard
)
public function WildcardToRegex( 
    wildcard: System.String
): System.String; 
public function WildcardToRegex( 
   wildcard : System.String
) : System.String;
public: System.string* WildcardToRegex( 
   System.string* wildcard
) 
public:
System.String^ WildcardToRegex( 
   System.String^ wildcard
) 

Parameters

wildcard
Example
FTP ftp = new FTP(); //Trial Mode            
//FTP ftp = new FTP("place user name here", "place license key here");
 
string wildcard = "*.cs";
string regexString = ftp.WildcardToRegex(wildcard);
 
Console.WriteLine("Pattern {0} was changed to {1}",wildcard,regexString);
Dim ftp As FTP = New FTP() 'Trial Mode
'FTP ftp = new FTP("place user name here", "place license key here");
 
Dim wildcard As String = "*.cs"
Dim regexString As String = ftp.WildcardToRegex(wildcard)
 
Console.WriteLine("Pattern {0} was changed to {1}",wildcard,regexString)
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

FTP Class
FTP Members