﻿<?xml version="1.0" encoding="utf-8"?><rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:media="http://search.yahoo.com/mrss/" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0"><channel><title>Intersoft Community - WebGrid Enterprise - WebGrid rowIndex equal 1 when click on filter row</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-rowIndex-equal-1-when-click-on-filter-row/</link><description /><generator>http://www.intersoftsolutions.com</generator><language>en</language><copyright>Copyright 2002 - 2015 Intersoft Solutions Corp. All rights reserved.</copyright><ttl>60</ttl><item><title>WebGrid rowIndex equal 1 when click on filter row</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-rowIndex-equal-1-when-click-on-filter-row/</link><pubDate>Thu, 19 Aug 2010 03:27:03 GMT</pubDate><dc:creator>niven</dc:creator><description>&lt;p&gt;Hi Nick,&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;
&lt;p&gt;Looks like in your issue, the rowindex can't be set and also to ignore the cell just for the filter.&lt;/p&gt;
&lt;p&gt;But you can do a validation, check whether the row is a filter or not.&lt;/p&gt;
&lt;p&gt;If you want, just look into the row type as the validation.&lt;/p&gt;
&lt;p&gt;Thanks!&lt;/p&gt;
&lt;p&gt;Hope this can help you.&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Niven Prasetya&lt;/p&gt;</description></item><item><title>WebGrid rowIndex equal 1 when click on filter row</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-rowIndex-equal-1-when-click-on-filter-row/</link><pubDate>Wed, 18 Aug 2010 18:26:21 GMT</pubDate><dc:creator>NK1958</dc:creator><description>&lt;span style="font-size: 13px"&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Hello InterSoft,&lt;/p&gt;&lt;p&gt;When I click field&amp;nbsp;in a WebGrid &lt;strong&gt;filter row&lt;/strong&gt; then WebGrid_OnCellClick function executed.&lt;/p&gt;&lt;p&gt;Somehow&amp;nbsp;rowindex became equal 1, which point me to 2nd row in a grid. &lt;/p&gt;&lt;p&gt;How to escape executing WebGrid_OnCellClick() by clicking on "Filter" row in a Grid&lt;/p&gt;&lt;p&gt;Or how to set rowindex equal -1 when clicking on Filter row&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;span style="font-size: 13px; color: #0000ff"&gt;&lt;span style="font-size: 13px; color: #0000ff"&gt;function&lt;/span&gt;&lt;/span&gt;&lt;span style="font-size: 13px"&gt; WebGrid_OnCellClick(gridId, tblName, &lt;strong&gt;rowIndex&lt;/strong&gt;, cellIndex, cellEl) { 

&lt;/span&gt;&lt;span style="font-size: 13px; color: #0000ff"&gt;&lt;span style="font-size: 13px; color: #0000ff"&gt;try&lt;/span&gt;&lt;/span&gt;&lt;span style="font-size: 13px"&gt; { 

&lt;/span&gt;&lt;span style="font-size: 13px; color: #0000ff"&gt;&lt;span style="font-size: 13px; color: #0000ff"&gt;var&lt;/span&gt;&lt;/span&gt;&lt;span style="font-size: 13px"&gt; grid=ISGetObject(gridId); 


&lt;/span&gt;&lt;span style="font-size: 13px; color: #0000ff"&gt;&lt;span style="font-size: 13px; color: #0000ff"&gt;var&lt;/span&gt;&lt;/span&gt;&lt;span style="font-size: 13px"&gt; wgRow = grid.RootTable.GetRow(rowIndex); 

&lt;/span&gt;&lt;span style="font-size: 13px; color: #0000ff"&gt;&lt;span style="font-size: 13px; color: #0000ff"&gt;var&lt;/span&gt;&lt;/span&gt;&lt;span style="font-size: 13px"&gt; htmlRow = wgRow.GetElement(); 

&lt;/span&gt;&lt;span style="font-size: 13px; color: #0000ff"&gt;&lt;span style="font-size: 13px; color: #0000ff"&gt;if&lt;/span&gt;&lt;/span&gt;&lt;span style="font-size: 13px"&gt;(!wgIsFilterRow(htmlRow)) 


&lt;/span&gt;&lt;span style="font-size: 13px; color: #008000"&gt;&lt;span style="font-size: 13px; color: #008000"&gt;//DO Code here &lt;/span&gt;&lt;/span&gt;&lt;span style="font-size: 13px"&gt;

} &lt;/span&gt;&lt;span style="font-size: 13px; color: #0000ff"&gt;&lt;span style="font-size: 13px; color: #0000ff"&gt;catch&lt;/span&gt;&lt;/span&gt;&lt;span style="font-size: 13px"&gt;(e) {} 

&lt;p&gt;}&lt;/p&gt;&lt;/span&gt;&lt;/span&gt;</description></item></channel></rss>