<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
<channel>
	<title>jQuery Grid Plugin - jqGrid - Topic: Implement grid event and call default event behavior?</title>
	<link>http://www.trirand.com/blog/?page_id=393/help/implement-grid-event-and-call-default-event-behavior</link>
	<description><![CDATA[Grid plugin]]></description>
	<generator>Simple:Press Version 5.7.5.3</generator>
	<atom:link href="http://www.trirand.com/blog/?page_id=393/help/implement-grid-event-and-call-default-event-behavior/rss" rel="self" type="application/rss+xml" />
        <item>
        	<title>markw65 on Implement grid event and call default event behavior?</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/implement-grid-event-and-call-default-event-behavior#p11978</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/implement-grid-event-and-call-default-event-behavior#p11978</guid>
        	        	<description><![CDATA[<p>Or, simpler and more efficient:</p>
</p>
<p><input type='button' class='sfcodeselect' name='sfselectit5429' value='Select Code' data-codeid='sfcode5429' /></p>
<div class='sfcode' id='sfcode5429'>beforeSelectRow:&#160;myBeforeSelectRow</div>
</p>
<p>(ie there&#39;s no need to wrap your handler in an anonymous function)</p>
</p>
<p>Mark</p></p>
]]></description>
        	        	<pubDate>Mon, 16 Nov 2009 08:28:29 +0200</pubDate>
        </item>
        <item>
        	<title>Sloub on Implement grid event and call default event behavior?</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/implement-grid-event-and-call-default-event-behavior#p11977</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/implement-grid-event-and-call-default-event-behavior#p11977</guid>
        	        	<description><![CDATA[<p>thank&#39;s dvorak, this works better with the return statement.</p>
</p>
<p>Sloub</p>
]]></description>
        	        	<pubDate>Mon, 16 Nov 2009 05:24:44 +0200</pubDate>
        </item>
        <item>
        	<title>dvorak on Implement grid event and call default event behavior?</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/implement-grid-event-and-call-default-event-behavior#p11972</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/implement-grid-event-and-call-default-event-behavior#p11972</guid>
        	        	<description><![CDATA[<p>This worked in my case in IE7/FF, etc.</p>
<p>Are you missing the return keyword in the beforeSelectRow() function?</p>
<p><em>beforeSelectRow: function(rowId, e) {<br />&#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; <strong>return </strong>myBeforeSelectRow(rowId,e);<br />}</em></p></p>
]]></description>
        	        	<pubDate>Mon, 16 Nov 2009 04:10:45 +0200</pubDate>
        </item>
        <item>
        	<title>Sloub on Implement grid event and call default event behavior?</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/implement-grid-event-and-call-default-event-behavior#p11971</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/implement-grid-event-and-call-default-event-behavior#p11971</guid>
        	        	<description><![CDATA[<p>Hello,</p>
</p>
<p>Is there something special to do for the "return true" to work ?</p>
<p>I had that first problem : <a href="http://www.trirand.com/blog/?page_id=393/help/tabletogrid-selcol-with-input-fields/" rel="nofollow" target="_blank"><a href="http://www.trirand.com/blog/?p" rel="nofollow">http://www.trirand.com/blog/?p</a>.....ut-fields/</a></p>
<p>Thank&#39;s to Mark, this is solved, except that in my case, the return true does not seem to execute default behaviour.</p>
</p>
<p style="padding-left: 30px;"><em>beforeSelectRow: function(rowId, e) {<br />&#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; myBeforeSelectRow(rowId,e);<br />}<br /></em></p>
<p style="padding-left: 30px;"><em>//outside the grid : this should act as default handler<br /></em></p>
<p style="padding-left: 30px;"><em>function myBeforeSelectRow(rowid, e) {<br />&#160;&#160;&#160;&#160;&#160;&#160;&#160; return true;<br />}</em></p>
<p>This code does not work for me, either on ie 6, nor firefox 3.x&#160; &#38; jqgrid 3.6</p>
</p>
<p>Thank&#39;s for your help</p>
<p>Sloub</p>
]]></description>
        	        	<pubDate>Mon, 16 Nov 2009 04:00:45 +0200</pubDate>
        </item>
        <item>
        	<title>dvorak on Implement grid event and call default event behavior?</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/implement-grid-event-and-call-default-event-behavior#p10621</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/implement-grid-event-and-call-default-event-behavior#p10621</guid>
        	        	<description><![CDATA[<p>Gotcha. That worked. Thanks Mark!</p>
]]></description>
        	        	<pubDate>Fri, 09 Oct 2009 18:06:38 +0300</pubDate>
        </item>
        <item>
        	<title>markw65 on Implement grid event and call default event behavior?</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/implement-grid-event-and-call-default-event-behavior#p10616</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/implement-grid-event-and-call-default-event-behavior#p10616</guid>
        	        	<description><![CDATA[<p>Unfortunately, the exact way to do this varies depending on the callback, but for the beforeSelectRow, just return "true".</p>
</p>
<p>Mark</p>
]]></description>
        	        	<pubDate>Fri, 09 Oct 2009 14:57:45 +0300</pubDate>
        </item>
        <item>
        	<title>dvorak on Implement grid event and call default event behavior?</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/implement-grid-event-and-call-default-event-behavior#p10606</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/implement-grid-event-and-call-default-event-behavior#p10606</guid>
        	        	<description><![CDATA[<p>Thanks for the reply Tony. Sorry, I don&#39;t think I explained my problem right. So jqgrid has default event behavior for when the user selects a row for example. If I implement an event, like beforeSelectRow, then the default behavior does not happen. Only what&#39;s in my beforeSelectRow function will be run. I&#39;m trying to find a way to have it do both. Execute jqgrid&#39;s default event behavior as well as my code.</p>
</p>
<p>beforeSelectRow: function(rowid) {</p>
<p>&#160;&#160;&#160; // do some custom code</p>
<p>&#160;&#160;&#160; // do jqgrid&#39;s default beforeSelectRow code</p>
<p>};</p>
]]></description>
        	        	<pubDate>Fri, 09 Oct 2009 12:06:53 +0300</pubDate>
        </item>
        <item>
        	<title>tony on Implement grid event and call default event behavior?</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/implement-grid-event-and-call-default-event-behavior#p10591</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/implement-grid-event-and-call-default-event-behavior#p10591</guid>
        	        	<description><![CDATA[<p>Hello,</p>
<p>For what I understand you can:</p>
<p><input type='button' class='sfcodeselect' name='sfselectit8138' value='Select Code' data-codeid='sfcode8138' /></p>
<div class='sfcode' id='sfcode8138'>
<p>beforeSelectRow: function(rowid, e)</p>
<p>{</p>
<p>myfunction();</p>
<p>}</p>
</p>
<p>Outside the grid</p>
<p>function myfunction ()</p>
<p>{</p>
<p>// do something</p>
<p>}</p>
</p>
<p>And then you can call it where you want</p>
</div>
<p>Tony</p>
]]></description>
        	        	<pubDate>Fri, 09 Oct 2009 04:24:15 +0300</pubDate>
        </item>
        <item>
        	<title>dvorak on Implement grid event and call default event behavior?</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/implement-grid-event-and-call-default-event-behavior#p10574</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/implement-grid-event-and-call-default-event-behavior#p10574</guid>
        	        	<description><![CDATA[<p>There are many very useful extension points in the grid however I often find that I&#39;d like the default behavior for an event to still take place, along with a bit of my code. So have it run the code in my function and then do what it normally would have done have I not provided this function.</p>
<p>For example, say I implement <em>beforeSelectRow</em> event:</p>
<p>beforeSelectRow: function(rowid) {</p>
<p>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; jQuery("#my_div").css({ "white-space" : "normal", "height" : "30px" });<br />},</p>
</p>
<p>Is there a way to then call the default beforeSelectRow() event handler in jqGrid? Something like base.beforeSelectRowI(rowid)?</p>
<p>I know this isn&#39;t exactly object oriented programming so, I&#39;m wondering if there&#39;s a way to emulate this behavior. use jquery&#39;s trigger event functionality?</p></p>
]]></description>
        	        	<pubDate>Thu, 08 Oct 2009 17:34:06 +0300</pubDate>
        </item>
</channel>
</rss>