I get my primary key after I insert a new record for the newly created record. If I refresh the page, I get all data fine but I dont want to refresh the entire page. I tried to do $('#mygrid').igGrid("dataBind") but this just bind the grid data what we have already on the page. New record is still not loaded with new primarykey which is returned from database.
How do I bind the primary key with the grid and new record? Please help.
Hello Sarojanand,
What version and build of the Ignite UI controls are you using? You can get this information with the following command in the browser's JavaScript console:
$.ui.igGrid.version
Also can you provide some sample JSON data? You can obtain it by inspecting the generated grid in the browser DOM. After the grid DOM there is a SCRIPT tag with code which initializes the grid. You can take it from there.
Best regards,Martin PavlovInfragistics, Inc.
Thank you for your update.
I have revised your code. In order to reproduce the issue and check if there is any type mismatches could you provide me a sample containing the views, the controllers and the models?
Thank you in advance.
Hi Dimka,
I worked on ur solution but this didn't work. Then I tried to implement sample from http://es.infragistics.com/community/forums/p/84192/420302.aspx#420302 which worked. I am able to see latest id in the grid but another problem arise now. If I click on the row to edit it after its inserted, all data in that row disappeard. Martin Povlov said its because of the datatype not mentioned in the columns. The problem persist even after I mentioned datatype on each column. i am now stuck at this point.
I am attaching the updated sample code. Please let me know if I m doing anything wrong or u have any suggestions.
If you need any further assistance or if you have any additional questions or concerns feel free to update this thread.