PasswordRecovery.FailureTextStyle プロパティ
アセンブリ: System.Web (system.web.dll 内)

エラー テキストの外観を定義するプロパティを格納している TableItemStyle への参照。

FailureTextStyle プロパティは、PasswordRecovery コントロールのエラー メッセージの外観を定義します。このプロパティは読み取り専用です。ただし、このプロパティが返す Style オブジェクトのプロパティを設定することはできます。これらのプロパティは、Property-Subproperty の形式で、宣言によって設定できます。ここで、Subproperty は Style クラスのプロパティを表します (例 : FailureTextStyle-ForeColor)。Property.Subproperty の形式でプロパティをプログラムによって設定できます (例 : FailureTextStyle.ForeColor)。
共通設定には、カスタムの背景色、テキストの色、およびフォントのプロパティが含まれます。FailureTextStyle プロパティは、次のプロパティの外観を定義します。
-
GeneralFailureText
-
QuestionFailureText
-
UserNameFailureText
FailureTextStyle プロパティのスタイル設定は、PasswordRecovery コントロールのスタイル設定とマージされます。FailureTextStyle プロパティで行われた設定は、PasswordRecovery コントロールのプロパティの対応する設定をオーバーライドします。
PasswordRecovery の次のスタイル プロパティは、FailureTextStyle 設定によってオーバーライドされます。
テンプレートを使用して PasswordRecovery コントロールの外観を定義した場合、FailureTextStyle プロパティは無効になります。

FailureTextStyle プロパティを使用して、PasswordRecovery コントロールのエラー メッセージのスタイル プロパティを設定するコード例を次に示します。
<%@ Page Language="VB" %> <script runat="server"> ' Insert page code here ' </script> <html> <head> </head> <body> <form runat="server"> <asp:PasswordRecovery id="PasswordRecovery1" runat="server" GeneralFailureText="You password cannot be retrieved at this time. Please try again later." QuestionFailureText="Your answer does not match the stored answer. Please try again." UserNameFailureText="We couldn't find that user name. Please try again."> <FailureTextStyle backcolor="Red" forecolor="White"></FailureTextStyle> </asp:PasswordRecovery> <!-- Insert content here --> </form> </body> </html>
<%@ Page Language="C#" %> <script runat="server"> </script> <html> <head> </head> <body> <form runat="server"> <asp:PasswordRecovery id="PasswordRecovery1" runat="server" GeneralFailureText="You password cannot be retrieved at this time. Please try again later." QuestionFailureText="Your answer does not match the stored answer. Please try again." UserNameFailureText="We couldn't find that user name. Please try again."> <FailureTextStyle backcolor="Red" forecolor="White"></FailureTextStyle> </asp:PasswordRecovery> </form> </body> </html>

Windows 98, Windows 2000 SP4, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
開発プラットフォームの中には、.NET Framework によってサポートされていないバージョンがあります。サポートされているバージョンについては、「システム要件」を参照してください。


Weblioに収録されているすべての辞書からPasswordRecovery.FailureTextStyle プロパティを検索する場合は、下記のリンクをクリックしてください。

- PasswordRecovery.FailureTextStyle プロパティのページへのリンク