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
empty rows (instead of form) to add records
13/10/2008
05:54
Avatar
paperogiallo
Member
Members
Forum Posts: 3
Member Since:
13/10/2008
sp_UserOfflineSmall Offline

Maybe this is already possible, but I can't figure out how (I'm a bad scripter, I have to admit)...

What I would like to do, is to add an empty row at the end of datagrid, making it editable so I can add record from the table, without the need of the form. Of course, after the new record is saved to the server, another empty row should be added to perform the same thing over and over. I saw I can add a custom button to the bar (I've done it, actually), so I think it's a matter to add a row with an empty id (the same way the form does, I suppose)... it's simply a matter of design, doesn't it?

I'm quite surprised that no one (I've searched the forum) had requested this feature in the past, I think it could be a great addon to this (really) cool script!

Bye, and thanks for your work!

13/10/2008
07:35
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

I think it is a simple.

Use addRowData method and you will have idea how to use it.

(you need only to add a empty value for some valid field)

$("#gridid").addRowData("emty_row",{colname:""},'last').editRow("empty_row");

Also see the 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.

13/10/2008
08:05
Avatar
paperogiallo
Member
Members
Forum Posts: 3
Member Since:
13/10/2008
sp_UserOfflineSmall Offline

Thank you very much for pointing me in the right direction (BTW, calling editRow triggers an error, but since I've tested, it's indeed not needed to do that to achieve the result I want).

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

Currently Online:
78 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