GrapeCity.Win.MultiRow.v80 アセンブリ > GrapeCity.Win.MultiRow 名前空間 : CellStyleNotify クラス |
Public Class CellStyleNotify Inherits AppearanceActionBase Implements INamedObject
public class CellStyleNotify : AppearanceActionBase, INamedObject
値が継承されていないプロパティだけが、アクションの実行時に外観に作用します。
InvalidCellStyleプロパティの設定は、セルのStyleプロパティの値には影響しません。
void setPairCharValidator_Click(object sender, EventArgs e) { Template template = Template.CreateGridTemplate(1); PairCharValidator pairCharValidator = new PairCharValidator(); pairCharValidator.PairChars.Add(new PairChar('(', ')')); CellStyleNotify cellStyleNotify = new CellStyleNotify(); cellStyleNotify.InvalidCellStyle.ForeColor = Color.Red; cellStyleNotify.InvalidCellStyle.Font = new Font(DefaultFont, FontStyle.Bold); cellStyleNotify.DoActionReason = ValidateReasons.EditedFormattedValueChanged; pairCharValidator.Actions.Add(cellStyleNotify); template.Row.Cells[0].Validators.Add(pairCharValidator); this.gcMultiRow1.Template = template; label.Text = "The PairCharValidator.PairChars is '( )', in edit mode, if you input '2*(3+4' to trigger validation, validation failed, the font will change, if input '2*(3+4)' to trigger validation, the validation success."; }
Private Sub setPairCharValidator_Click(ByVal sender As Object, ByVal e As EventArgs) Handles setPairCharValidator.Click Dim template As Template = template.CreateGridTemplate(1) Dim pairCharValidator As New PairCharValidator() pairCharValidator.PairChars.Add(New PairChar("("c, ")"c)) Dim cellStyleNotify As New CellStyleNotify() cellStyleNotify.InvalidCellStyle.ForeColor = Color.Red cellStyleNotify.InvalidCellStyle.Font = New Font(DefaultFont, FontStyle.Bold) cellStyleNotify.DoActionReason = ValidateReasons.EditedFormattedValueChanged pairCharValidator.Actions.Add(cellStyleNotify) template.Row.Cells(0).Validators.Add(pairCharValidator) Me.gcMultiRow1.Template = template label.Text = "The PairCharValidator.PairChars is '( )', in edit mode, if you input '2*(3+4' to trigger validation, validation failed, the font will change, if input '2*(3+4)' to trigger validation, the validation success." End Sub
System.Object
GrapeCity.Win.MultiRow.CellValidateAction
GrapeCity.Win.MultiRow.AppearanceActionBase
GrapeCity.Win.MultiRow.CellStyleNotify