TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Adhikar Patil
NA
481
128.9k
How to reload jqgrid after deleting the data
Feb 19 2019 2:45 AM
Hello,
I have jqgrid with data. I have an problem like after deleting the record in jqgrid is not loading with refresh data.
Below is my Code. Please give me the solution
onclickSubmit:
function
(response, postdata){
var
rowData = jQuery(
this
).jqGrid(
'getRowData'
, postdata);
$.ajax({
type:
"POST"
,
url:
"/Element/DeleteElementData"
,
data: { Id: rowData.ID },
error:
function
(xhr, status, error) {
toastr.error(
'An error occured while deleting the record...'
); },
success:
function
(response) {
if
(response.IsSuccess) {
toastr.success(response.Message);
ReloadGrid(); }
else
{
toastr.error(response.Message); } }
});
function
ReloadGrid() {
// $("#ElementsGrid").setGridParam({ url: '/Element/GetElementDefectData' }).trigger('reloadGrid', { fromServer: true });
$(
"#ElementsGrid"
).jqGrid(
"setGridParam"
, { datatype:
"json"
})
.trigger(
"reloadGrid"
, [{ current:
true
}]); }
Reply
Answers (
5
)
Need Help on validation of Kendo GRID - Inline EDIT - Jquery
dynamic graphs generate by using kendo and jquery