Hi,

I have table in Database and i need to get the get the values of column and check for the values. If the value in row of that column is null...the imagebutton in grid view should be disabled.
I am unable to get the rows values.

Can anyone help??

Thanks in Advance.

Hello,

Hope this works

<asp:TemplateField>
			<ItemTemplate>
				<asp:ImageButton ID="ibtnTestBtn" ImageUrl="yourimageURI.jpg" Enabled='<%#IIf(IsDBNull(DataBinder.Eval(Container, "DataItem.ColumnName")), True, False)%>' runat="server" />
			</ItemTemplate>
		</asp:TemplateField>
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.