How do I make some cells (or column of cells) read only? I have five columns I display to the user. Only one column should be editable, the other four columns are informational only and need to be made read only, but I'm not finding a behavior to do this.
Hi,
on page load i make readonly using following statement "<ig:EditingColumnSetting ColumnKey="abc" ReadOnly="true" />" and on checkbox click i am calling js function on event "
CellEditingClientEvents-EnteredEditMode" where i need to make "abc" cell editable but it wont work,please look in this issue. i want to make cell readonly & editable on click event.
Thanks,
Hi Maya,
I am creating a dynamic boundedcheckbox field at the runtime. one issue is there,
When I am adding a new row, the new added row boundedcheckbox field should b e editable and other remaining rows boundedcheckbox field should be non-editable.
How to acheive this?
Please do the needful.
Thanks in Advance.
Maya,
That is what I needed and thanks for the sample! Cheers!
Hello dbishop9 ,
You can set a whole column to be read only through the CellEditing behavior like this:
<ig:CellEditing>
<ColumnSettings>
<ig:EditingColumnSetting ColumnKey="id" ReadOnly="true" />
</ColumnSettings>
</ig:CellEditing>
This will set the specified column to be Read only.
The approach David proposed is also applicable especially if you would like to make a specific cell read only.
The WebDataGrid has the method EnteringEditMode. It can be found in EditGrid Behaviors in Cell Editing ->CellEditingClientEvents
or you can manually set it like this(inside the Cell editing behavior):
<CellEditingClientEvents EnteringEditMode="WebDataGrid1_CellEditing_EnteringEditMode" />
I’m attaching a sample for you reference. Let me know if you need further assistance regarding this.
Best Regards,
Maya Kirova
Developer Support Engineer
Infragistics, Inc.
http://es.infragistics.com/support
Thanks, but the post you directed me to is for a WebHierarchialDataGrid, not a WebDataGrid, they have different methods and the WHDG method used (EnteringEditMode) doesnt exist for WebDataGrid. Also, there is no column setting suggestion given. The column setting is what i am looking for. Can you suggest the column setting method, because it isn't obvious in the inellisense dropdown for a WebDataGrid Column. Thanks.