Query |
Solution |
Move the current cell focus. |
We had created the simple as per your scenario and the current cell focus has been changed via MoveTo method of CurrentCell. Please refer the attached sample and please let us know if we missed anything in your customization. It would be more helpful for us to provide the exact solution at the earliest. |
How can I prevent the user to add row to prevent the GCC to add invalid row |
We had analyzed your query in our end and need some additional details regarding the validation done in your current cell. The GridGroupingControl have built-in support for validating the current cell value by enabling the property ShowErrorIcon, ShowErrorMessageBox via the CurrentCell property. This will restrict the invalid cell value being entered in the cell. Please let us know if we misunderstood anything. |
Query |
Response |
this.gridGroupingControl1.Table.CurrentRecord is null, |
When editing is completed for the current record and if another record has been clicked then at that moment no record is been edited and Table.CurrentRecord becomes null. Hence we request you to put null check condition. Please refer the sample for more information. |
Can I restrict user to add row when the CategoryName is string.empty |
Please make use of the below code to achieve your requirement. Please refer the below sample for more information.
if (this.gridGroupingControl1.Table.CurrentRecord != null && this.gridGroupingControl1.Table.CurrentRecord["CategoryName"] != null)
{
string value = this.gridGroupingControl1.Table.CurrentRecord["CategoryName"].ToString();
if(string.IsNullOrEmpty(value))
{
value = "Value is empty";
}
}
|
The result is that , it may go to error exception on issue 1 |
As requested before we request you to put null check condition to overcome this issue. Please refer the below sample and let us know if you still experience any issues. |
Thank you for your update.