﻿<?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 and Custom Virtual Loading</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-and-Custom-Virtual-Loading/</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 and Custom Virtual Loading</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-and-Custom-Virtual-Loading/</link><pubDate>Wed, 01 Aug 2012 20:26:51 GMT</pubDate><dc:creator>bernard</dc:creator><description>Hi John,&lt;br /&gt;&lt;br /&gt;If you have any misconfiguration in my code, please let me know. I'll gladly help you to solve your problem.&lt;br /&gt;&lt;br /&gt;Regards,&lt;br /&gt;Bernard&lt;br /&gt;</description></item><item><title>WebGrid and Custom Virtual Loading</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-and-Custom-Virtual-Loading/</link><pubDate>Wed, 01 Aug 2012 06:59:50 GMT</pubDate><dc:creator>John.Bonin@dot.gov</dc:creator><description>&lt;p&gt;Thanks Bernard,  I'll take a look and will get back to you if I have any questions.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt; &lt;/p&gt;</description></item><item><title>WebGrid and Custom Virtual Loading</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-and-Custom-Virtual-Loading/</link><pubDate>Tue, 31 Jul 2012 00:52:48 GMT</pubDate><dc:creator>bernard</dc:creator><description>Hi John,&lt;div&gt;&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;Sorry for my late response. For this problem, I've a sample that using ObjectDataSource as WebGrid's DataSource. ObjectDataSource take a class as CustomObject and bind it into WebGrid. WebGrid also takes parameter in ObjectDataSource to configure the ClassicPaging's Custom PagingLoadMode. I also attach the sample here. Hope this helps.&lt;/div&gt;
&lt;div&gt;&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;Regards,&lt;/div&gt;
&lt;div&gt;Bernard&lt;/div&gt;</description></item><item><title>WebGrid and Custom Virtual Loading</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-and-Custom-Virtual-Loading/</link><pubDate>Fri, 27 Jul 2012 06:50:39 GMT</pubDate><dc:creator>John.Bonin@dot.gov</dc:creator><description>Hi Bernard,&lt;br /&gt;&lt;br /&gt;&amp;nbsp;&amp;nbsp; I've read the documentation before and that's why I ask a question here.&amp;nbsp; The documentation uses a DataSet, I don't want to use the DataSet TableAdapter.&amp;nbsp; I want to use a data class that acesses an Oracle Data Package.&amp;nbsp; I guess from everything thus far, it is not possible to use this functionality without creating a dataset, so I guess I need to find a different solution.&lt;br /&gt;&lt;br /&gt;Thanks&lt;br /&gt;</description></item><item><title>WebGrid and Custom Virtual Loading</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-and-Custom-Virtual-Loading/</link><pubDate>Thu, 26 Jul 2012 22:05:15 GMT</pubDate><dc:creator>bernard</dc:creator><description>&lt;p&gt;Hi John,&lt;/p&gt;&lt;p&gt;I think this walkthough will help you. You can go to WebGrid's Documentation (&lt;a href="http://intersoftpt.com/Support/WebGrid/Documentation/" style="font-size: 10pt; "&gt;http://intersoftpt.com/Support/WebGrid/Documentation/&lt;/a&gt;), go to Walkthrough Topics tab, then you can see Walkthrough: Implementing Custom Paging using ISDataSource inside Paging Data sub topic. &lt;/p&gt;
&lt;p&gt;Hope this helps.&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;&lt;/p&gt;
&lt;p&gt;Regards,&lt;/p&gt;
&lt;p&gt;Bernard&lt;/p&gt;</description></item><item><title>WebGrid and Custom Virtual Loading</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-and-Custom-Virtual-Loading/</link><pubDate>Thu, 26 Jul 2012 06:58:58 GMT</pubDate><dc:creator>John.Bonin@dot.gov</dc:creator><description>Hi Bernard,&lt;br /&gt;&lt;br /&gt;&amp;nbsp; I started using the ISDAtaSource but I guess I am still missing something as the maximumRows and startRowIndex is not sent to the control.&lt;br /&gt;&lt;br /&gt;Here is the code for the ISDataSource within the aspx file with webGrid:&lt;br /&gt;&lt;pre&gt;&amp;lt;isdatasource:isdatasource id="ISDataSource1" runat="server"    schematype="CustomObject" LoadOnDemand="True"&amp;gt;
    &amp;lt;tables&amp;gt;
        &amp;lt;ISDataSource:ISDataSourceTable SelectMethod="getAllRDR" TypeName="RDRDetails" 
            TableName="RDRTable" SelectCountMethod="getAllRDRCount" EnablePaging="true"&amp;gt;
            &amp;lt;SelectParameters&amp;gt;
                &amp;lt;asp:Parameter Name="_userID" Type="String" /&amp;gt;
                &amp;lt;asp:Parameter Name="_where" Type="String" /&amp;gt;
                &amp;lt;asp:Parameter Name="startRowIndex" Type="Int32" /&amp;gt;
                &amp;lt;asp:Parameter Name="maximumRows" Type="Int32" /&amp;gt;
                &amp;lt;asp:Parameter Name="sortExpression" Type="String" /&amp;gt;
            &amp;lt;/SelectParameters&amp;gt;
        &amp;lt;/ISDataSource:ISDataSourceTable&amp;gt;
    &amp;lt;/tables&amp;gt;
&amp;lt;/isdatasource:isdatasource&amp;gt;&lt;br /&gt;&lt;br /&gt;Here is the function getAllRDR in the Class object:&lt;br /&gt;    &amp;lt;System.ComponentModel.DataObjectMethodAttribute(System.ComponentModel.DataObjectMethodType.Select, False)&amp;gt; _
        Public Function getAllRDR(ByVal _userID As String, ByVal _where As String, ByVal startRowIndex As Integer, ByVal maximumRows As Integer, ByVal sortExpression As String) As DataTable
        Dim reader As OracleDataReader = Nothing
        Dim oDT As DataTable = New DataTable()
        _where = Replace(_where, "AND ", "WHERE ")
        Using conn As OracleConnection = New OracleConnection(ConfigurationManager.ConnectionStrings("conn").ToString)
            Dim cmd As OracleCommand = conn.CreateCommand()
            conn.Open()
            cmd.CommandText = "data_access.get_all_rdrs"
            cmd.CommandType = CommandType.StoredProcedure
            cmd.Parameters.Add("p_user", OracleDbType.Varchar2).Value = _userID
            cmd.Parameters.Add("p_where", OracleDbType.Varchar2).Value = _where
            cmd.Parameters.Add("p_start", OracleDbType.Decimal).Value = startRowIndex
            cmd.Parameters.Add("p_max", OracleDbType.Decimal).Value = maximumRows
            cmd.Parameters.Add("p_sort", OracleDbType.Varchar2).Value = sortExpression
            cmd.Parameters.Add("out_data", OracleDbType.RefCursor).Direction = ParameterDirection.InputOutput
            reader = cmd.ExecuteReader
            oDT.Load(reader, LoadOption.OverwriteChanges)
            reader.Close()
            Return oDT
        End Using
    End Function&lt;/pre&gt;
&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;pre&gt;When I put a breakpoint in the getALLRDR class an look at the parameters, startRowIndex and maximumRows is zero.&lt;br /&gt;&lt;br /&gt;Not sure what I am missing here...&lt;br /&gt;&lt;br /&gt;thanks&lt;br /&gt;&lt;/pre&gt;
&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;br /&gt;
</description></item><item><title>WebGrid and Custom Virtual Loading</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-and-Custom-Virtual-Loading/</link><pubDate>Thu, 26 Jul 2012 04:14:47 GMT</pubDate><dc:creator>bernard</dc:creator><description>&lt;p /&gt;&lt;p&gt;Hi John,&lt;/p&gt;
&lt;p&gt;Actually, you couldn't do Custom PagingLoadMode in ClassicPaging without using DataSource. WebGrid automatically sends the parameter to DataSource so it can configure its Paging. Currently, only ISDataSource and ObjectDataSource that support Paging. However, I recommend you to use ISDataSource for this scenario. ISDataSource can takes data from your class as CustomObject so you can do your paging. Hope this helps.&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;&lt;/p&gt;
&lt;p&gt;Regards,&lt;/p&gt;
&lt;p&gt;Bernard&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;&lt;/p&gt;
&lt;p&gt;For more information, see http://intersoftpt.com/Support/WebGrid/Documentation/#url=topic511.html&lt;/p&gt;
&lt;p /&gt;</description></item><item><title>WebGrid and Custom Virtual Loading</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-and-Custom-Virtual-Loading/</link><pubDate>Wed, 25 Jul 2012 06:42:01 GMT</pubDate><dc:creator>John.Bonin@dot.gov</dc:creator><description>&lt;p&gt;Thanks Bernard, I'm not looking to display the index.  I guess I didn't explain what I need.&lt;/p&gt;
&lt;p&gt;I have database that has over 120K records, I want to use Custom Loading and Classic paging.  I have a data class that calls an Oracle data package that gets the startRowIndex, maximumRecors and sortExpression which then returns 50 records at a time, when the user moved to the next page, the grid gets the next 50 records.  I don't want to use a DataSource control and have my code pass these parameters to my data class.  My question is can I do this without a data source control?&lt;/p&gt;</description></item><item><title>WebGrid and Custom Virtual Loading</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-and-Custom-Virtual-Loading/</link><pubDate>Tue, 24 Jul 2012 23:26:59 GMT</pubDate><dc:creator>bernard</dc:creator><description>&lt;p&gt;Hi John,&lt;/p&gt;
&lt;p&gt;From information that you mentioned above, you want to make Classic paging that show the index of data that has been loaded to WebGrid. You can do this with ClassicPaging but you must handle the index in client-side event.&lt;/p&gt;
&lt;p&gt;I've made my own sample that show your scenario. In my sample I'm using Access Database instead of Oracle Database. And I'm not using DataSourceControl like your scenario. I attach my sample here.&lt;/p&gt;
&lt;p&gt;Hope this helps.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;Regards,&lt;/p&gt;
&lt;p&gt;Bernard&lt;/p&gt;</description></item><item><title>WebGrid and Custom Virtual Loading</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-and-Custom-Virtual-Loading/</link><pubDate>Tue, 24 Jul 2012 12:04:32 GMT</pubDate><dc:creator>John.Bonin@dot.gov</dc:creator><description>&lt;p&gt;I'm loading a grid using the InitializeDataSource event calling a Data Class to get 50 rows of data from an oracle database.  In the InitializeDataSource event, I can get the sortExpression and the number of records to bring back, but I can't figure out how to get the startRowIndex from.  I know it's simple but can't sem to figure it out!&lt;/p&gt;
&lt;p&gt; MORE:  I see that for PagingMode="VirtualLoad" this works fine, but I want to do ClassicPaging.  Is there a way to do Custom Loading and Classic Paging without using a DataSource control?&lt;/p&gt;
&lt;p&gt;Thanks&lt;/p&gt;
&lt;p&gt;john&lt;/p&gt;</description></item></channel></rss>