Quantcast
Channel: Web Forms
Viewing all articles
Browse latest Browse all 23244

Need change the color for a string in VB.Net

$
0
0

Hi,

In vb.net code behind file i validate each column value before it got bind to the cell values in a gridview, is there is no data for a cell then i need display an error message in that particular cell with different color.

I need to color the error message in Red color before i assign the error message to a cell in gridview. 

I tried many ways added style in format tag, then tried for Font color tag but nothing is working.

_hasErrors = True
                        Me.ViewState("hasErrors") = True
                        row.Item("entityID1") = String.Format("<b><Font color ='red'>Error - Please enter an entity name for the primary relationship...</Font></b>")




Viewing all articles
Browse latest Browse all 23244

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>