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
Passing Parameters to the Grid
08/01/2010
17:44
Avatar
bfancett
Canton, MI
New Member
Members
Forum Posts: 2
Member Since:
07/01/2010
sp_UserOfflineSmall Offline

I have implemented the jQuery Grid into my ASP.NET MVC application, and have seen numerous examples on how to load the grid in the documet.ready function, however I need to do it otherwise.

I need to show the grid after the user has entered some information in a couple (2) textboxes and then clicked a button (search).  The jQuery Grid will display the results of the search.  This is impossible to do though without being able to pass these 2 parameters into the grid so that when it goes to the url 'MSF/DynamicGridData/' along with the sortname, sort order, page, etc., parameters it also passes in the values from my 2 textboxes.

I haven't got a clue how to do this, but it seems that I Grid for displaying data wouldn'e be much good if it didn't take parameters somehow. 

Please help!

Thanks,

Brian

10/01/2010
13:09
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

Is your button search custom or integraded on the pager?

If you button is custom you can use setGridParam and pass the needed values to postData arrray

$("#mybutton").click(function(){

$("#mygrid").setGridParam({postData:{item1:val1....});

// do a serch here

});

If you use the integraded search button on pager use the beforeShowSearch event and do the same with the posData

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:
65 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