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
Is "afterShowForm" event for View & Search in "navGrid" section supported?
11/10/2012
20:36
Avatar
nelsonm
Michigan, USA
Member
Members
Forum Posts: 106
Member Since:
20/08/2011
sp_UserOfflineSmall Offline

Hi all,

It appears that the "afterShowForm" event for View & Search in "navGrid" section is not supported.  Is this correct?

I ask because i currently use jQuery's ".position" utility to keep jqGrid forms centered in the browser window on load and when the browser window is resized. It works great in the "afterShowForm" event functions for edit, add, and delete forms in the "navGrid" section, but not for view or search.

The following "afterShowForm" events initially position the jqGrid form in the center of the browser window but the view and search "afterShowForm" event appear not to work:

var wko1EditEventASF = function(formid) {

   var grid  = formid.selector.replace('FrmGrid_','editmod');

   $('#editmod'+grid).position({my:'center', at:'center', of:window, collision: 'fit'});

}

var wko1DelEventASF = function(formid) {

   var grid  = formid.selector.replace('DelTbl_','delmod');

   $('#delmod'+grid).position({my:'center', at:'center', of:window, collision: 'fit'});

}

var wko1ViewEventASF = function(formid) {

   var grid  = formid.selector.replace('ViewGrid_','viewmod');

   $('#viewmod'+grid).position({my:'center', at:'center', of:window, collision: 'fit'});

}

var wko1SearchEventASF = function(formid) {

   var grid  = formid.selector.replace('fbox_','searchmodfbox_');

   $('#searchmodfbox_'+grid).position({my:'center', at:'center', of:window, collision: 'fit'});

}

The following code keeps the position of the jqGrid forms (when one is called for) in the center of the browser window when browser window is resized – all work:

$(function() {

   $(window).resize(function(event){

      var grid = id of grid.

      $('#editmod'+grid              ).position({my:'center', at:'center', of:window, collision: 'fit'});

      $('#delmod'+grid               ).position({my:'center', at:'center', of:window, collision: 'fit'});

      $('#viewmod'+grid             ).position({my:'center', at:'center', of:window, collision: 'fit'});

      $('#searchmodfbox_'+grid ).position({my:'center', at:'center', of:window, collision: 'fit'});

   });

});

So, it would be nice to be able to trigger the  "afterShowForm" event for View & Search in "navGrid" section.

Thanks.

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

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