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.
hi friends,
i am displaying data in griddataboundgrid
from datasourse and there is a boolean column in table but i am showing image through imagelist on every cell of that column but i am not able to set the alignment of that image.
plz help
ADAdministrator Syncfusion Team April 18, 2006 02:55 PM UTC
Hi Brijesh,
To set the Horizontal/Vertical alignment of the Image, you need to set the GridImageSizeMode to Normal. Below is a code snippet.
style.ImageSizeMode =GridImageSizeMode.Normal;
style.HorizontalAlignment = GridHorizontalAlignment.Right;
style.VerticalAlignment = GridVerticalAlignment.Top;
Regards,
Calvin.
BRbrijeshkhareApril 19, 2006 05:17 AM UTC
>hi friends,
>
>i am displaying data in griddataboundgrid
>from datasourse and there is a boolean column in table but i am showing image through imagelist on every cell of that column but i am not able to set the alignment of that image.
>
>
>plz help
i have tried this property but it is not working
when i use e.Style.CellType = "ImageCell"
i am not able to set the aligment of image.
ADAdministrator Syncfusion Team April 19, 2006 09:34 AM UTC
Hi Brijesh,
The CellType must be set to “Image” or GridCellTypeName.Image. Below is a code snippet that works fine for me. Let us know if you are trying something different.
e.Style.CellType = "Image"; // GridCellTypeName.Image;
e.Style.ImageList = this.imageList;
e.Style.ImageSizeMode = GridImageSizeMode.Normal;
e.Style.HorizontalAlignment = GridHorizontalAlignment.Right;
e.Style.VerticalAlignment = GridVerticalAlignment.Top;
Regards,
Calvin.
BRbrijeshkhareApril 19, 2006 11:28 AM UTC
>Hi Brijesh,
>
>The CellType must be set to “Image” or GridCellTypeName.Image. Below is a code snippet that works fine for me. Let us know if you are trying something different.
>
> e.Style.CellType = "Image"; // GridCellTypeName.Image;
> e.Style.ImageList = this.imageList;
> e.Style.ImageSizeMode = GridImageSizeMode.Normal;
> e.Style.HorizontalAlignment = GridHorizontalAlignment.Right;
> e.Style.VerticalAlignment = GridVerticalAlignment.Top;
>
>Regards,
>Calvin.
thanks Calvin
now it is working fine