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
populate select boxes with multiple values
22/08/2009
11:21
Avatar
mandarin
Guest
Guests

Hello!

I have added a row to my grid which has edittype set to select, and multiple to true. It shows in the grid, but it's filling in the data which is the problem. I have tried to insert an array in the JSON object, but to no success.

This is the model:

index:'ship', editoptions:{multiple:true, value:{1:"FedEx",2:"InTime",3:"TNT",4:"ARAMEX"}}

And here's what I've tried submitting:

ship:{[1],[4]}

ship:[[1],[4]]

ship:{value:{1,4}}

...and lots of other variations.

I've searched the forum over and over again but can't seem to find anyone else who has had the same problem. Does anyone know how to fix this?

Best regards,

Thomas

22/08/2009
13:51
Avatar
mandarin
Guest
Guests

Sorry about that. I'm just being stupid.

I never thought it did work because jqGrid renders multiple values as a string. That made me believe something was wrong, and instead of clicking the cell to see what would happend, I spent a few hours looking for the answer on the internet.

This is how you do it:

ship:["FedEx","TNT"]

Easy as that.

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

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