GrapeCity.Win.CalendarGrid.v10 アセンブリ > GrapeCity.Win.CalendarGrid 名前空間 > CalendarRadioGroupCellType クラス : FlatStyle プロパティ |
例外 | 解説 |
---|---|
System.ComponentModel.InvalidEnumArgumentException | 指定された値が System.Windows.Forms.FlatStyle 値ではありません。 |
このプロパティの値が System.Windows.Forms.FlatStyle.Flat の場合、ラジオボタンの外観は背景が単色のフラットな外観になります。
このプロパティの値が System.Windows.Forms.FlatStyle.Popup の場合、ラジオボタンの外観は通常はフラットで、ユーザーがセルにマウスを合わせるかセルをクリックすると、ポップアップします。
このプロパティの値が System.Windows.Forms.FlatStyle.System または System.Windows.Forms.FlatStyle.Standard の場合、ラジオボタンの外観はオペレーティングシステムによって決定されます。
private void Form1_Load(object sender, EventArgs e) { CalendarRadioGroupCellType radioGroupCell1 = new CalendarRadioGroupCellType(); for (int i = 1; i < 7; i++) { radioGroupCell1.Items.Add(i.ToString()); } radioGroupCell1.CheckAlign = ContentAlignment.MiddleLeft; //6 radio will be lay out to 3 columns. radioGroupCell1.ColumnCount = 3; //The radio button will range from left to right. radioGroupCell1.FlowDirection = Orientation.Horizontal; //Between every 2 columns, 20 pixels space exists at least. radioGroupCell1.HorizontalSpace = 20; radioGroupCell1.FlatStyle = FlatStyle.Popup; CalendarRadioGroupCellType radioGroupCell2 = new CalendarRadioGroupCellType(); radioGroupCell2.Items.Add("11111"); radioGroupCell2.Items.Add("22222"); radioGroupCell2.Items.Add("33333"); radioGroupCell2.Items.Add("44444"); radioGroupCell2.Items.Add("55555"); radioGroupCell2.Items.Add("66666"); radioGroupCell2.CheckAlign = ContentAlignment.MiddleLeft; //6 radio will be lay out to 3 columns. radioGroupCell2.ColumnCount = 3; //The radio button will range from top to bottom. radioGroupCell2.FlowDirection = Orientation.Vertical; //Between every 2 lines, 20 pixels space exists at least. radioGroupCell2.VerticalSpace = 20; // radioGroupCell2.Ellipsis = CalendarGridEllipsisMode.EllipsisEnd; radioGroupCell2.EllipsisString = "..."; CalendarTemplate template1 = CalendarTemplate.CreateDefaultTemplate(); template1.Content.Columns[0].Width = 150; template1.Content.Rows[1].Height = 60; template1.Content.Rows[2].Height = 60; template1.Content[1, 0].CellType = radioGroupCell1; template1.Content[2, 0].CellType = radioGroupCell2; gcCalendarGrid1.Template = template1; }
Private Sub Form1_Load(sender As Object, e As EventArgs) Dim radioGroupCell1 As New CalendarRadioGroupCellType() For i As Integer = 1 To 6 radioGroupCell1.Items.Add(i.ToString()) Next radioGroupCell1.CheckAlign = ContentAlignment.MiddleLeft '6 radio will be lay out to 3 columns. radioGroupCell1.ColumnCount = 3 'The radio button will range from left to right. radioGroupCell1.FlowDirection = Orientation.Horizontal 'Between every 2 columns, 20 pixels space exists at least. radioGroupCell1.HorizontalSpace = 20 radioGroupCell1.FlatStyle = FlatStyle.Popup Dim radioGroupCell2 As New CalendarRadioGroupCellType() radioGroupCell2.Items.Add("11111") radioGroupCell2.Items.Add("22222") radioGroupCell2.Items.Add("33333") radioGroupCell2.Items.Add("44444") radioGroupCell2.Items.Add("55555") radioGroupCell2.Items.Add("66666") radioGroupCell2.CheckAlign = ContentAlignment.MiddleLeft '6 radio will be lay out to 3 columns. radioGroupCell2.ColumnCount = 3 'The radio button will range from top to bottom. radioGroupCell2.FlowDirection = Orientation.Vertical 'Between every 2 lines, 20 pixels space exists at least. radioGroupCell2.VerticalSpace = 20 ' radioGroupCell2.Ellipsis = CalendarGridEllipsisMode.EllipsisEnd radioGroupCell2.EllipsisString = "..." Dim template1 As CalendarTemplate = CalendarTemplate.CreateDefaultTemplate() template1.Content.Columns(0).Width = 150 template1.Content.Rows(1).Height = 60 template1.Content.Rows(2).Height = 60 template1.Content(1, 0).CellType = radioGroupCell1 template1.Content(2, 0).CellType = radioGroupCell2 gcCalendarGrid1.Template = template1 End Sub