Forum

November 2nd, 2014
A A A
Avatar

Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

The forums are currently locked and only available for read only access
sp_Feed Topic RSS sp_TopicIcon
Row Edit, Save new values to Grid & Array. Possible??
04/12/2008
00:42
Avatar
robtani
Member
Members
Forum Posts: 10
Member Since:
08/11/2008
sp_UserOfflineSmall Offline

Hi,

I am binding the Grid to an array and wanted to save the changed values of a row (After Edit)  back to the array instead of posting it to another page. 

 I haven't seen any examples in the Demo pages doing this.  All the examples want to post to another page.  Does anyone have any idea how I could do this? The Row needs to go in the Edit mode when the user clicks the row and I need to save the capture the new values back to the grid (& underlying Array).

Thank you.

04/12/2008
12:59
Avatar
tony
Sofia, Bulgaria
Moderator
Members

Moderators
Forum Posts: 7721
Member Since:
30/10/2007
sp_UserOfflineSmall Offline

Hello,

Never mind that this can be used. If you can - set the url to one dummy

existing file on server and them perform the needed operations.

beforeSubmit and afterSubmit events have a parameter a array of the

posted data which can be used.

Regards

For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.

05/12/2008
20:16
Avatar
robtani
Member
Members
Forum Posts: 10
Member Since:
08/11/2008
sp_UserOfflineSmall Offline

Thank you for the feedback.

I can't get those 2 events to fire.  I tried many variations.  Here's the sample I tried for the beforeSubmit event:

jQuery("#grd").jqGrid({ datatype: "local", width: 185, height: 165, colNames:
        ['Position', 'Start', 'Filled'],
                    colModel: [
          { name: 'Pos', index: 'Pos', width: 45, align: "center", sorttype: "string" },
          { name: 'St', index: 'St', width: 36, align: "center", sorttype: "int", editable: true },
          { name: 'Max', index: 'Max', width: 36, align: "center", sorttype: "int", editable: true}], imgpath: gridimgpath,
                    multiselect: false, shrinkToFit: false, onSelectRow: function(id) {
                        if (id && id !== lastsel2) {
                            jQuery('#grd').restoreRow(lastsel2);
                            jQuery('#grd').editRow(id, true, oneditme, saveme);
                            lastsel2 = id;
                        }
                    }, beforeSubmit: function(id) { alert('about to submit'); }, afterSubmit: befSubmit, editurl: "test.aspx", caption: "Roster Needs"
                });

Any idea what the problem is? 

09/12/2008
06:46
Avatar
tony
Sofia, Bulgaria
Moderator
Members

Moderators
Forum Posts: 7721
Member Since:
30/10/2007
sp_UserOfflineSmall Offline

Hello,

You have mix formedit with inline edit. Also refer to docs.

Regards

Tony

For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

Currently Online:
63 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

OlegK: 1255

markw65: 179

kobruleht: 144

phicarre: 132

YamilBracho: 124

Renso: 118

Member Stats:

Guest Posters: 447

Members: 11373

Moderators: 2

Admins: 1

Forum Stats:

Groups: 1

Forums: 8

Topics: 10592

Posts: 31289

Newest Members:

, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.com

Moderators: tony: 7721, Rumen[Trirand]: 81

Administrators: admin: 66

Comments are closed.
Privacy Policy   Terms and Conditions   Contact Information