Forum

July 12th, 2025
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
navgrid example help
31/10/2009
07:26
Avatar
ploppy
Member
Members
Forum Posts: 38
Member Since:
28/10/2009
sp_UserOfflineSmall Offline

hi

 i have been looking at http://www.secondpersonplural......m for examples on jqgrid. there is an example that i am interested in following on navigator, but cannot get the search(find) function to work. in the code,

jQuery("#tbleditable").navGrid('#pcustbut',{edit:false,add:false,del:false})
   .navButtonAdd('#pcustbut',{caption:"Edit",
   onClickButton:function(){
      var gsr = jQuery("#custbut").getGridParam('selrow');
      if(gsr){
         jQuery("#custbut").GridToForm(gsr,"#order");
      } else {
         alert("Please select Row")
      }                    
}
});

what do the #pcustbut and #order relate to? for example, in the  code i have, do they relate to list2 and pager2?

<table id="list2" class="scroll" cellpadding="0" cellspacing="0"></table>
<div id="pager2" class="scroll" style="text-align:left;"></div>

also, the search button is appearing on the grid, but when i press it does not find anything. do i need a php page to collect data? if so, is there a code example somewhere? many thanks

Wish i knew more about jqGrid

01/11/2009
06:13
Avatar
ploppy
Member
Members
Forum Posts: 38
Member Since:
28/10/2009
sp_UserOfflineSmall Offline

any help with this please? even read the manual would have been helpful. (which i have) many thanks

Wish i knew more about jqGrid

01/11/2009
08:00
Avatar
Rumen Stankov
Guest
Guests

The first parameter to navButtonAdd is the ID of pager, e.g. in your case "#pager2". The second parameter was just taken out of context from the example, in reality, you just do not need it. For example this is how you can have a "Toggle Filtering ToolBar" button in your toolbar

.navGrid('#pager2',{edit:false,add:false,del:false,search:false,refresh:false}) .navButtonAdd("#pager2",{caption:"Toggle",title:"Toggle Search Toolbar", buttonicon :'ui-icon-pin-s', onClickButton:function(){ mygrid[0].toggleToolbar() } })

There is a PDF help file in the Download section of this site, please download and open it and check out the "Custom Buttons" section.

Rumen Stankov

Trirand

01/11/2009
10:29
Avatar
ploppy
Member
Members
Forum Posts: 38
Member Since:
28/10/2009
sp_UserOfflineSmall Offline

thank you very much Rumen. much appreciated.

Wish i knew more about jqGrid

Forum Timezone: Europe/Sofia

Most Users Ever Online: 994

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