Validates the format of an entry name for a phone book. This class cannot be inherited.
Namespace: DotRas
Assembly: DotRas (in DotRas.dll) Version: 1.3.5166.33435 (1.3.0.0)
Syntax
C# |
public sealed class RasEntryNameValidator
|
Visual Basic |
Public NotInheritable Class RasEntryNameValidator
|
Visual C++ |
public ref class RasEntryNameValidator sealed
|
F# |
[<SealedAttribute>]
type RasEntryNameValidator = class end
|
Remarks
Examples
The following example shows how to use the
RasEntryNameValidator to validate an entry does not already exist within a phone book. After the
Validate()()()() method has been called, the
IsValid property will indicate whether the entry name is valid.
C# | Copy |
---|
RasEntryNameValidator validator = new RasEntryNameValidator();
validator.EntryName = "VPN Connection";
validator.PhoneBookPath = RasPhoneBook.GetPhoneBookPath(RasPhoneBookType.AllUsers);
validator.AllowExistingEntries = false;
validator.Validate(); |
Visual Basic | Copy |
---|
Dim validator As New RasEntryNameValidator
validator.EntryName = "VPN Connection"
validator.PhoneBookPath = RasPhoneBook.GetPhoneBookPath(RasPhoneBookType.AllUsers)
validator.AllowExistingEntries = False
validator.Validate() |
Inheritance Hierarchy
See Also