Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
830
Enabling row adding on demand
posted

Hi,

 

How can I allow row adding in a webdatagrid only after the user clicks on a certain button; ideally if he clicks on an icon on the 1st row itself.

 

I mean, is it possible to make the row adding row disabled and put an icon on its selector, so the user can t enter values at first, but after he clicks on that icon, he can enter values and add the row later after clicking save. 

 

if not pissible, can I enable adding a row , only on demand through some client script if user clicks a button somewhere on the page ?

 

Thank u :)

Parents
  • 33839
    Verified Answer
    posted

    Hi rtutus,

    It is not possible to enable and disable the row adding behavior on the client.  However you could probably manage to do this.  To put an image or something in the add row row selector, you could use the css class available for that.  Then you would want to attach a client click handler to the row selector.  In this click event, you could set a global boolean java script variable to true.  In the row adding entering edit mode client event, you would need to cancel it if that var had not been set to true.  As I mentioned in your other post, it is not truly possible to add the row on the client by default.  But you could cancel row adding and do what I said in that post or you could simply keep the values in the add row until you commit on the click of the other save button.

    regards,
    David Young 

Reply Children
No Data