Hello. I have a grid where the user can set the Primary key value of the table. This is great, but I don't want them editing that value.
I only want the edit field to show up on creates. I want it to be locked for normal edits.
If i set it to .Editable(False) then I can't add new ones.
I tried putting and onEdit event in which called a javascript which sought out that cell and called the .closecell() but that didn't work. Maybe I was doing something wrong.
Is there an easy bit of javascript for closing cell 4 on an edit of an existing item.
I've added what I think I should be using..i'm just missing something...please help!
I only want the edit field to show up on creates. I want it to be locked for normal edits.
If i set it to .Editable(False) then I can't add new ones.
I tried putting and onEdit event in which called a javascript which sought out that cell and called the .closecell() but that didn't work. Maybe I was doing something wrong.
Is there an easy bit of javascript for closing cell 4 on an edit of an existing item.
I've added what I think I should be using..i'm just missing something...please help!
<script> function onEdit(e) { //if the model isn't new (editing) if (!e.model.isNew()) { var grid = $("#Devices").data("kendoGrid"); //missing code I want her grid.closecell(); } }</script>