Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

My question is are there ways to get control row by row of what a datagrid does, based on values of the dataset the datagrid is bound to?

 

For example, I have a dataset with values. The datagrid displays these. A user can click edit to edit the row, which brings up a control designated in the edittemplate tag, textbox, listbox, etc. I want to be able to either disable the edit linkbutton from appearing, or disable the edittemplate item control, if the row has a certain value in one of its fields.

 

Is this possible? Does this even make sense?

Posted

It is possible to do but you need to creater your own column style and then add a handler and do your own paint method to this to help you format the cell based on the contents on the cell.

Look for an example of how to change the color of the text in a box based on the contents, You should be able to build on that to do what you need.

Hamlet

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...