The Syncfusion native Blazor components library offers 70+ UI and Data Viz web controls that are responsive and lightweight for building modern web apps.
.NET PDF framework is a high-performance and comprehensive library used to create, read, merge, split, secure, edit, view, and review PDF files in C#/VB.NET.
I have recreated a custom cell type on a GridControl and would like to style it in QueryCellInfo (using e.Style if possible). How would you suggest is a good way of doing that?
ADAdministrator Syncfusion Team November 12, 2003 12:37 PM
So you have derived CellModel and CellRenderer classes to define your custom cell type.
If so, then if you use grid.CellModels.Add to add a name and instance for your custom celltype to the grid's CellModels collection, you should be able to use your celltype anywhere just like any other celltype. So in QueryCellInfo, you would set e.Style.CellType = "myName" where myName is the string you registered in grid.CellModels.Add.
ADAdministrator Syncfusion Team November 12, 2003 12:37 PM
So you have derived CellModel and CellRenderer classes to define your custom cell type.
If so, then if you use grid.CellModels.Add to add a name and instance for your custom celltype to the grid's CellModels collection, you should be able to use your celltype anywhere just like any other celltype. So in QueryCellInfo, you would set e.Style.CellType = "myName" where myName is the string you registered in grid.CellModels.Add.
TMTrevor MoodyNovember 13, 2003 01:18 AM
Yes, I have done that. However, for example for a progress bar, you will put e.Style.ProgressBar.(ProgressBarProperty) = progressbarproperty to set a property of the progressbar cell.
How can I set a property of the custom cell in the same way if e.Style.CellType == "CustomCell"?
ADAdministrator Syncfusion Team November 13, 2003 05:30 PM
Take a look at the Essential Suite\Grid\Samples\CellTypes\SliderCells sample. It shows how to derive custom style properties. Look at the SliderStyleProperties class in the SliderCell.cs file.