DataGrid.ResetForeColor メソッドとは? わかりやすく解説

Weblio 辞書 > コンピュータ > .NET Framework クラス ライブラリ リファレンス > DataGrid.ResetForeColor メソッドの意味・解説 

DataGrid.ResetForeColor メソッド

ForeColor プロパティ既定値リセットします。

名前空間: System.Windows.Forms
アセンブリ: System.Windows.Forms (system.windows.forms.dll 内)
構文構文

Public Overrides Sub ResetForeColor
Dim instance As DataGrid

instance.ResetForeColor
public override void ResetForeColor ()
public:
virtual void ResetForeColor () override
public void ResetForeColor ()
解説解説

通常、System.Windows.Forms.DataGrid のデザイナ作成する場合、または System.Windows.Forms.DataGrid組み込まれている独自のコントロール作成する場合に、このメソッド使用します

使用例使用例
' String variable used to show message.
Dim myString As String =
 "Selection backgound color changed from: "
' Store current foreground color of selected cells.
Dim myCurrentColor As Color = myDataGrid.SelectionBackColor
myString += myCurrentColor.ToString()
' Reset selection background color to default.
myDataGrid.ResetSelectionBackColor()
myString += "  to "
myString += myDataGrid.SelectionBackColor.ToString()
' Show information about changes in color setting.  
MessageBox.Show(myString, "Selection background color information")
// String variable used to show message.
string myString = "Selection backgound color changed from:
 ";
// Store current foreground color of selected cells.
Color myCurrentColor = myDataGrid.SelectionBackColor;
myString += myCurrentColor.ToString();
// Reset selection background color to default.
myDataGrid.ResetSelectionBackColor();
myString += "  to ";
myString += myDataGrid.SelectionBackColor.ToString();
// Show information about changes in color setting.  
MessageBox.Show(myString, "Selection background color information");
// String variable used to show message.
String^ myString = "Selection backgound color changed from: ";

// Store current foreground color of selected cells.
Color myCurrentColor = myDataGrid->SelectionBackColor;
myString = String::Concat( myString, myCurrentColor.ToString() );

// Reset selection background color to default.
myDataGrid->ResetSelectionBackColor();
myString = String::Concat( myString, " to " );
myString = String::Concat( myString, myDataGrid->SelectionBackColor.ToString()
 );

// Show information about changes in color setting.  
MessageBox::Show( myString, "Selection background color information" );
// String variable used to show message.
String myString = "Selection backgound color changed from: ";

// Store current foreground color of selected cells.
Color myCurrentColor = myDataGrid.get_SelectionBackColor();

myString += myCurrentColor.ToString();

// Reset selection background color to default.
myDataGrid.ResetSelectionBackColor();
myString += "  to ";
myString += myDataGrid.get_SelectionBackColor().ToString();

// Show information about changes in color setting.  
MessageBox.Show(myString, "Selection background color information");
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
DataGrid クラス
DataGrid メンバ
System.Windows.Forms 名前空間
AlternatingBackColor
BackColor
CaptionBackColor
CaptionForeColor
ForeColor
ResetAlternatingBackColor



英和和英テキスト翻訳>> Weblio翻訳
英語⇒日本語日本語⇒英語
  

辞書ショートカット

すべての辞書の索引

DataGrid.ResetForeColor メソッドのお隣キーワード
検索ランキング

   

英語⇒日本語
日本語⇒英語
   



DataGrid.ResetForeColor メソッドのページの著作権
Weblio 辞書 情報提供元は 参加元一覧 にて確認できます。

   
日本マイクロソフト株式会社日本マイクロソフト株式会社
© 2024 Microsoft.All rights reserved.

©2024 GRAS Group, Inc.RSS