JqGrid is getting displayed as a non editable modal inside a jquery dialog

Darbo

New Member
I am using the jquery dialog and displaying JqGrid inside the jquery dialog box. Everything is working perfectly fine, But the JqGrid is getting displayed as a non editable modal. So i couldn edit anything inside the dialog box.Even if i close and reopen the dialog box it remains the same, only if i refresh the page it becomes normal until that the whole dialog box is displaying as a non editable modal... The code logic works well and good.. It seems to be an UI issue.. Kindly help me out..Anyhow I am posting my code below for your reference..kindly view that and help me in resolving the issue..This is my aspx code:\[code\]<div><span id="span_create" style="color: #88b807; margin-left: 839px; margin-top: -12px; cursor: pointer; display: block">Create</span></div> <div id="Createdialog" style="display: none; overflow: hidden"> <table id="table" style="border-spacing: 7px 7px; margin-left: 5px"> <tr> <td> <span class="SubHeading" style="font-size: 10pt;">Private Space Name </span> </td> <td> <asp:TextBox ID="txt_spacename" runat="server" /> </td> </tr> <tr> <td> <span class="SubHeading" style="font-size: 10pt;">Users </span> </td> <td> <asp:TextBox ID="txt_users" TextMode="MultiLine" runat="server" /> </td> <td> <asp:Button ID="btn_addusers" Text="Add" Style="margin-left: 0px;" runat="server" /> </td> </tr> <tr> <td> <table id="users_grid"> </table> </td> </tr> </table> <input type="button" id="Btn_Submit" value="http://stackoverflow.com/questions/13803619/Create" style="margin-left: 280px; margin-top: 8px;" runat="server" /> </div>\[/code\]This is my Js code: \[code\]$("#Createdialog").dialog({ autoOpen: false, title: 'Create Private space', modal: true, position: 'center', width: 900 }); $('#span_create').click(function() { $("#Createdialog").find('input:text, textarea').val(''); $('#Createdialog').dialog('open'); return false; });$('#btn_addusers').click(function() { $("#users_grid").jqGrid({ colNames: ['User_ID', 'Name', 'Email_Id'], colModel: [{ name: 'User_ID', index: 'User ID', width: 130, editable: false, sortable: false }, { name: 'Name', index: 'Name', width: 350, editable: false, sortable: false }, { name: 'Email_Id', index: 'Email Id', width: 350, editable: false, sortable: false}], width: 400, height: 'auto', multiselect: true, modal: false }); var UserID = $('#Header1_txt_users').val(); var datapost = {}; datapost.UserId = UserID; var postJSONData = http://stackoverflow.com/questions/13803619/JSON.stringify({'postdata': JSON.stringify(datapost) }); $.ajax({ type: 'POST', data: postJSONData, url: 'PrivateSpaceService.asmx/GetUserDetails', dataType: 'json', async: false, contentType: 'application/json; charset=utf-8', success: function success(response) { UserArr = response.d; }, error: function failure(response) { alert('failed'); } }); var mydata; for (var i = 0; i < UserArr.length; i++) { mydata = http://stackoverflow.com/questions/13803619/{}; mydata.User_ID = UserArr.UserId; mydata.Name = UserArr.UserName; mydata.Email_Id = UserArr.EmailId; $("#users_grid").jqGrid('addRowData', 'GridData_Row_' + (i + 1), mydata); } return false; });\[/code\]
 
Back
Top