You can select a color in the pop-up cell by using the System.Windows.Forms.ColorDialog.
Using the Designer
- Add a pop-up cell to the row (for example: popupCell1).
- Add a ColorDialog to the row (for example: colorDialog1).
- Select popupCell1, then select the popupCell1.Popup property from the Properties window and click the ellipses button.
- In the displayed Popup screen, expand the tree, and select colorDialog1.
- Click the OK button and close the dialog.
- Select popupCell1, then select the popupCell1.PopupValueMember property from the Properties window and select Color from the drop-down window.
- Change the designer document window tab to Runtime.
- Click the popupCell1 button and confirm the Set Color dialog option.
- Select any color from the Set Color dialog and click the OK button.
- In the input area of popupCell1, check the selected color string.
Using Code
This example provides a color dialog.
[VB]
Imports GrapeCity.Win.MultiRow
Dim popupCell1 As New PopupCell()
popupCell1.Popup = New ColorDialog()
popupCell1.PopupValueMember = "Color"
GcMultiRow1.Template = Template.CreateGridTemplate(New Cell() { popupCell1 })
GcMultiRow1.RowCount = 10
|
[CS]
using GrapeCity.Win.MultiRow;
PopupCell popupCell1 = new PopupCell();
popupCell1.Popup = new ColorDialog();
popupCell1.PopupValueMember = "Color";
gcMultiRow1.Template = Template.CreateGridTemplate(new Cell[] { popupCell1 });
gcMultiRow1.RowCount = 10;
|
See Also