When I try to Pass an ID in the " Store.Load({params: ( " my PAGING starts up with "NaN" as the first page...

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1

    When I try to Pass an ID in the " Store.Load({params: ( " my PAGING starts up with "NaN" as the first page...

    I'm using Paging and if works fine, the ONLY issue I have is when I try to pass a value in the Parameter in the Store as stated below, the Grid loads up fine, but the Window in the Paging in the bottom of the Grid shows "NaN" for the FIRST Page...

    I track down the reason to this:
    ProductsStore.load({ params: { productGroupID: 999} });

    If I comment these lines out and replace it with ProductsStore.load(); and HARD CODE the value (eg. 999), PAGING WORKS FINE...

                <ext:GridPanel ID="gpProductGroup" runat="server" Height="450" StoreID="ProductGroupStore"
                    TrackMouseOver="true" Title="Manage Product Group Names" StripeRows="true" AutoScroll="true"
                    <ColumnModel ID="ColumnModel1" runat="server">
                            <ext:Column DataIndex="Description" Header="Product Group Name" Sortable="true" />
                            <ext:Column Header="Status" DataIndex="Status" Sortable="true">
                                <Renderer Fn="formatStatus" />
                            <ext:CommandColumn Width="50">
                                    <ext:GridCommand CommandName="Edit" Text="Edit Product Group" Icon="ApplicationEdit" />
                            <ext:CommandColumn Width="50">
                                    <ext:GridCommand CommandName="Delete" Icon="Delete" Text="Delete this group" />
                        <ext:RowSelectionModel ID="RowSelectionModel1" runat="server" SingleSelect="true" />
                        <ext:GridView ID="gvProductGroup" runat="server" ForceFit="true">
                        <Command Fn="commandHandler" />
            var commandHandler = function(cmd, record) {
                record = record.data;
                if (cmd == "Edit") {
                    AddProductsToGroupWindow.setTitle('Modify Product Group');
                    var productGroupIdValue = record.ProductGroupID;
                    if (productGroupIdValue != "")
                        // Load ProductsStore with Product Groups...
                        ProductsStore.load({ params: { productGroupID: 999} });
                    PopulateModalData(record.ProductGroupID, record.Description, record.Status);
                else if (cmd == "Delete") {
                    Ext.Msg.confirm("Confirm", "Are you sure you wish to delete this product group?", function(result) {
                        if (result == "yes") {
                            Coolite.AjaxMethods.ProductGroup.DeleteProductGroup(record.ProductGroupID, {
                                success: function(result) {
                                failure: function(result) {
                                eventMask: {
                                    showMask: true,
                                    msg: "Updating Grid..."

            Public Overrides Sub ProcessRequest(ByVal context As System.Web.HttpContext)
                Dim productGroupId As Integer = context.Request(PRODUCT_GROUP_ID).AsInt(0)
            End Sub
    This value 999 come through but once again, the first Page in the Grid for Paging says, "NaN"
    Last edited by RonaldR; Jun 21, 2011 at 4:16 PM. Reason: I updated the Code as per sample below, same issue...

Similar Threads

  1. [CLOSED] How does "MaskCls" work for "AutoLoad" mask in panel control
    By leon_tang in forum 1.x Legacy Premium Help
    Replies: 5
    Last Post: Jul 19, 2012, 12:09 PM
  2. Replies: 1
    Last Post: Jun 26, 2012, 11:29 AM
  3. Replies: 4
    Last Post: May 22, 2012, 10:40 AM
  4. Replies: 5
    Last Post: May 02, 2012, 5:37 PM
  5. Replies: 4
    Last Post: Oct 11, 2011, 2:42 AM

Posting Permissions