BaseValidatorDesigner::GetDesignTimeHtml Method
Gets the markup that is used to render the associated control at design time.
Assembly: System.Design (in System.Design.dll)
Return Value
Type: System::StringA string containing the markup used to render the BaseValidator at design time.
If the ErrorMessage or Text property of the associated control that is derived from the BaseValidator class is an empty string (""), or if the Display property is set to the None field, the GetDesignTimeHtml method sets the ErrorMessage property to the control ID, which is enclosed in brackets ([]) and sets the Display property to the Static field. The GetDesignTimeHtml then calls the GetDesignTimeHtml base method to generate the markup, and restores the control properties to their original values, if necessary.
The following code example shows how to override the GetDesignTimeHtml method that draws a solid border around the associated control at design time if the value of the BorderStyle property of the control is set to the NotSet or None field.
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.
Windows 7, Windows Vista, Windows XP SP2, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP Starter Edition, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003, Windows Server 2000 SP4, Windows Millennium Edition, Windows 98
The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.