﻿<?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 with FullPagePostback and multiple selection enabled</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-with-FullPagePostback-and-multiple-selection-enabled/</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 with FullPagePostback and multiple selection enabled</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-with-FullPagePostback-and-multiple-selection-enabled/</link><pubDate>Mon, 03 Aug 2015 01:19:40 GMT</pubDate><dc:creator>yudi</dc:creator><description>&lt;blockquote&gt;... We're using IE11 so maybe that has something to do with it.&lt;/blockquote&gt;&lt;p&gt;&lt;span style="color: #1f497d;"&gt;For your information, I'm using WebGrid 9 rendered on IE11 browser.&lt;/span&gt;&lt;/p&gt;
&lt;blockquote&gt;... Using the OnRowSelect client event for the selection grid I trigger an update to the transaction grid. Accomplishes the same thing without having to refresh the whole page (and avoids this row selection bug).&lt;/blockquote&gt;
&lt;p&gt;&lt;span style="color: #1f497d;"&gt;Glad to hear that the OnRowSelect suits your scenario.&lt;br&gt;Should you need further assistance or run into any problems regarding our controls, feel free to post it into our forum. We would be happy to assist you again.&lt;/span&gt;&lt;/p&gt;</description></item><item><title>WebGrid with FullPagePostback and multiple selection enabled</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-with-FullPagePostback-and-multiple-selection-enabled/</link><pubDate>Thu, 30 Jul 2015 12:06:52 GMT</pubDate><dc:creator>belvin@nbpower.com</dc:creator><description>&lt;p&gt;Interesting, it doesn't work for us here. We're using IE11 so maybe that has something to do with it. &lt;/p&gt;&lt;p&gt;In the end I did find an alternate (and perhaps better) way to go about what I was trying to do. Using the OnRowSelect client event for the selection grid I trigger an update to the transaction grid. Accomplishes the same thing without having to refresh the whole page (and avoids this row selection bug). &lt;br&gt;&lt;/p&gt;</description></item><item><title>WebGrid with FullPagePostback and multiple selection enabled</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-with-FullPagePostback-and-multiple-selection-enabled/</link><pubDate>Thu, 30 Jul 2015 02:33:34 GMT</pubDate><dc:creator>yudi</dc:creator><description>&lt;blockquote&gt;So, if you modify the PageLoad event in your sample to check for this situation, like I did with the attached code, it demonstrates the behaviour I've been seeing (that the first selected item is dropped from the display after the postback).&lt;/blockquote&gt;&lt;p&gt;&lt;span style="color: #1f497d;"&gt;I modified the code in Page_Load so it now looks like following:&lt;/span&gt;&lt;/p&gt;
&lt;pre&gt;    Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load

        Dim checkedRows As ArrayList = WebGrid1.RootTable.GetCheckedRows()

        txtSelectedRows.Visible = True
        Dim text As String = "Checked rows: " &amp;amp; checkedRows.Count &amp;amp; vbLf &amp;amp; vbLf

        For Each keyValue As String In checkedRows
            text &amp;amp;= keyValue &amp;amp; ";"
        Next keyValue

        If checkedRows.Count = 0 Then
            text = WebGrid1.SelectedRowKeyValue()
        End If

        txtSelectedRows.Text = text
    End Sub&lt;/pre&gt;
&lt;p&gt;&lt;span style="color: #1f497d;"&gt;Save the changes and view the page in browser. The first selected item is not dropped from the display after postback. Please check the attached video which taken when test the scenario.&lt;/span&gt;&lt;/p&gt;</description></item><item><title>WebGrid with FullPagePostback and multiple selection enabled</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-with-FullPagePostback-and-multiple-selection-enabled/</link><pubDate>Mon, 27 Jul 2015 14:38:34 GMT</pubDate><dc:creator>belvin@nbpower.com</dc:creator><description>&lt;p&gt;Looks like the "insert code" feature didn't actually insert the code that I can see. I'll attach it as a zip.&lt;br&gt;&lt;/p&gt;</description></item><item><title>WebGrid with FullPagePostback and multiple selection enabled</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-with-FullPagePostback-and-multiple-selection-enabled/</link><pubDate>Mon, 27 Jul 2015 14:33:21 GMT</pubDate><dc:creator>belvin@nbpower.com</dc:creator><description>&lt;p&gt;I added your sample to the WebGridSamples project and ran it. It works fine as-is, it seems to correctly handle the row count after the postback.&lt;/p&gt;&lt;p&gt;However, note that your sample isn't checking something important. When multi-row selection is turned on but the user doesn't select multiple rows, they just&amp;nbsp;select one, the GetCheckedRows() function doesn't return that row. To get the selected row you have to issue the single row selection function, SelectedRowKeyValue(), instead.&lt;/p&gt;&lt;p&gt;So, if you modify the PageLoad event in your sample to check for this situation, like I did with the attached code, it demonstrates the behaviour I've been seeing (that the first selected item is dropped from the display after the postback).&lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;</description></item><item><title>WebGrid with FullPagePostback and multiple selection enabled</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-with-FullPagePostback-and-multiple-selection-enabled/</link><pubDate>Mon, 27 Jul 2015 08:58:23 GMT</pubDate><dc:creator>yudi</dc:creator><description>&lt;p&gt;&lt;span style="color: #1f497d;"&gt;I created a sample of WebGrid based on the code in WebForm1.aspx in the sent GridTest project. Please add my sample in WebGridSamples project and view the page in browser.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color: #1f497d;"&gt;By using this sample, WebGrid is correctly shows selected rows when user clicking a range with Shift + click (from top row to bottom). However, problem happens when user clicking a range from bottom row to top using Shift + click or random click by holding Ctrl key.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="color: #1f497d;"&gt;I need your help to get more information regarding this problem before I forward this to WebGrid development team. Please feel free to let me know if you have different result or find another selection problem.&lt;/span&gt;&lt;/p&gt;</description></item><item><title>WebGrid with FullPagePostback and multiple selection enabled</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-with-FullPagePostback-and-multiple-selection-enabled/</link><pubDate>Wed, 08 Jul 2015 12:53:07 GMT</pubDate><dc:creator>belvin@nbpower.com</dc:creator><description>&lt;p&gt;I took this a step further I made a tiny sample project to demonstrate my issue (which is attached). It&amp;nbsp;has a grid and a text box that lists the selected rows. &lt;/p&gt;&lt;p&gt;If you look in the PageLoad event there's code to list the selected rows in the textbox. If that code is commented out the grid seems to work ok. Uncomment that code&amp;nbsp;and the&amp;nbsp;behaviour changes;&amp;nbsp;clicking a range with shift+click no longer remembers the first selected row. &lt;/p&gt;&lt;p&gt;The PageLoad code doesn't try to affect the list of selected rows, it merely reports what the list is, but it seems that asking for the list actually causes the behaviour to change.&lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;</description></item><item><title>WebGrid with FullPagePostback and multiple selection enabled</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-with-FullPagePostback-and-multiple-selection-enabled/</link><pubDate>Wed, 08 Jul 2015 11:53:30 GMT</pubDate><dc:creator>belvin@nbpower.com</dc:creator><description>&lt;p&gt;Thanks for your reply. I tried the same modifications to the MultipleRowSelection.aspx sample file that you described above (plus added&amp;nbsp;some row highlighting styles to make them stand out more). On the first postback it does seem to retain all of the selected rows but if you keep playing with it after that first postback you'll notice it isn't working. You can't unselect any row no matter what you do and if you click the "Show Selected Rows" button that your sample has it says&amp;nbsp;no rows are selected.&lt;/p&gt;&lt;p&gt;Attached are the modified version of the sample grid that I tried and a picture showing highlighted rows while also claiming that no rows are selected.&lt;br&gt;&lt;/p&gt;</description></item><item><title>WebGrid with FullPagePostback and multiple selection enabled</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-with-FullPagePostback-and-multiple-selection-enabled/</link><pubDate>Wed, 08 Jul 2015 03:27:48 GMT</pubDate><dc:creator>yudi</dc:creator><description>&lt;p&gt;&lt;span style="color: #1f497d;"&gt;Based on your information, I modified MultipleRowSelection.aspx sample file of WebGrid by applying following configuration:&lt;/span&gt;&lt;/p&gt;&lt;ul style="color: #1f497d;"&gt;&lt;li&gt;AllowMultipleSelection="Yes"&lt;/li&gt;&lt;li&gt;RestoreRowSelection="All"&lt;/li&gt;&lt;li&gt;PersistRowChecker="false"&lt;/li&gt;&lt;li&gt;RowChangedAction="FullPagePostback"&lt;/li&gt;&lt;/ul&gt;
&lt;p&gt;&lt;span style="color: #1f497d;"&gt;Next, a breakpoint in Page_Load event is added. At this point, &lt;strong&gt;WebGrid1.RootTable.GetCheckedRows()&lt;/strong&gt; is invoked to retrieve selected rows.&lt;/span&gt;&lt;/p&gt;
&lt;blockquote&gt;Selecting multiple rows has a problem though, the grid looses track of the first selected row. For example selecting 3 rows with shift+left click causes the grid to only show 2 selected rows after the postback. Selecting individual rows with ctrl+left click causes previously selected rows to disappear.&lt;/blockquote&gt;
&lt;p&gt;&lt;span style="color: #1f497d;"&gt;I tried to reproduce the problem in my local tests by selecting multiple rows using shift+left click or ctrl+left click but my efforts were not successful -- GetCheckedRows() returns correct number of selected rows.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="color: #1f497d;"&gt;Should you find anything that I might miss during my attempt to reproduce the reported problem, please feel free let me know.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="color: #1f497d;"&gt;Note: if necessary, I can provide you with the modified sample of MultipleRowSelection.aspx sample file of WebGrid.&lt;/span&gt;&lt;/p&gt;</description></item><item><title>WebGrid with FullPagePostback and multiple selection enabled</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-with-FullPagePostback-and-multiple-selection-enabled/</link><pubDate>Tue, 30 Jun 2015 13:48:02 GMT</pubDate><dc:creator>belvin@nbpower.com</dc:creator><description>&lt;p&gt;I have a webgrid that's trying to use all these features at once:&lt;/p&gt;&lt;ul&gt;&lt;li&gt;multiple row selection using selected rows (i.e. not the row checker column) with &lt;span color="#ff0000" face="Consolas" size="2"&gt;&lt;span color="#ff0000" face="Consolas" size="2"&gt;&lt;span color="#ff0000" face="Consolas" size="2"&gt;AllowMultipleSelection&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span color="#0000ff" face="Consolas" size="2"&gt;&lt;span color="#0000ff" face="Consolas" size="2"&gt;&lt;span color="#0000ff" face="Consolas" size="2"&gt;="Yes"&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li&gt;persist selected rows with &lt;span color="#ff0000" face="Consolas" size="2"&gt;&lt;span color="#ff0000" face="Consolas" size="2"&gt;&lt;span color="#ff0000" face="Consolas" size="2"&gt;RestoreRowSelection&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span color="#0000ff" face="Consolas" size="2"&gt;&lt;span color="#0000ff" face="Consolas" size="2"&gt;&lt;span color="#0000ff" face="Consolas" size="2"&gt;="All" and &lt;span color="#ff0000" face="Consolas" size="2"&gt;&lt;span color="#ff0000" face="Consolas" size="2"&gt;&lt;span color="#ff0000" face="Consolas" size="2"&gt;PersistRowChecker&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span color="#0000ff" face="Consolas" size="2"&gt;&lt;span color="#0000ff" face="Consolas" size="2"&gt;&lt;span color="#0000ff" face="Consolas" size="2"&gt;="false"&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li&gt;full page postback on selected row change with &lt;span color="#ff0000" face="Consolas" size="2"&gt;&lt;span color="#ff0000" face="Consolas" size="2"&gt;&lt;span color="#ff0000" face="Consolas" size="2"&gt;RowChangedAction&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span color="#0000ff" face="Consolas" size="2"&gt;&lt;span color="#0000ff" face="Consolas" size="2"&gt;&lt;span color="#0000ff" face="Consolas" size="2"&gt;="FullPagePostback"&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;The scenario is this grids acts as selection criteria for the user. Selecting a row should immediately return the search results for that row (hence the reason for the fullpagepostback) and selecting multiple rows should returns the results for multiple items.&lt;/p&gt;&lt;p&gt;The issue is around selecting multiple items. Selecting one row works great: the post back fires, the server-side code checks the selected items and retrieves&amp;nbsp;data, and the results are displayed. Selecting multiple rows has a problem though, the grid looses track of the first selected row. For example selecting 3 rows with shift+left click causes the grid to only show 2 selected rows after the postback. Selecting individual rows with ctrl+left click causes previously selected rows to disappear. &lt;/p&gt;&lt;p&gt;The grid works fine if FullPagePostback is not turned on, it will select single rows or multiple rows without a problem. However, the users don't like hitting a Search button after making their selections and want it to happen automatically, hence the postback. Multiple row selection doesn't seem to get along with FullPagePostback though.&lt;/p&gt;&lt;p&gt;Is there a way to get this to work? I tried using the IsRowChecker column instead of selected rows but it still has the same issue with loosing track of which rows are selected during the postbacks.&lt;/p&gt;</description></item></channel></rss>