Hi
I have field IsActive as Bit DataType in Sql. If it is true i want Tick Box like below image should get displayed
@Html.DisplayNameFor(model => model.IsActive)

Thanks
Hi
I have field IsActive as Bit DataType in Sql. If it is true i want Tick Box like below image should get displayed

Thanks
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Sachin SinghPosted Jun 15, 2021, 4:29 PM
style="color:blue">Ramco RamcoPosted Jun 15, 2021, 4:24 PM
Hi Sachin
I want Tick should appear in blue color.
@foreach (var item in Model.Locations)
{
@Html.DisplayFor(model => item.Id)
@Html.DisplayFor(model => item.Description)
@if(item.IsActive)
{
}
else
{
}
Thanks
Sachin SinghPosted Jun 15, 2021, 4:15 PM
Ramco RamcoPosted Jun 15, 2021, 4:03 PM
Hi Sachin
Even in Active also it is printing X
@if (item.IsActive)
{
}
else
{
}
Thanks
Sachin SinghPosted Jun 15, 2021, 3:53 PM
Ramco RamcoPosted Jun 15, 2021, 3:43 PM
Sachin SinghPosted Jun 15, 2021, 12:19 PM