[CLOSED] How to add new Parameter In v2.3

  1. #1

    [CLOSED] How to add new Parameter In v2.3

    There is a store where I have added new Parameter in V1.1 but now in V2.3 I could not add new Parameter when I try to add new Parameter in store I got the Error/Exception "This operation requires IIS integrated pipeline mode.

    "
    for Detail I have also attach the detail image

    Code That add new parameter in store
     this.store_Units.Parameters.Add(new Ext.Net.Parameter("ICategory", value.ToString(), ParameterMode.Raw));
    <%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<dynamic>" %>
    <%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
    <script runat="server">
        protected override void OnInit(EventArgs e)
        {
            this.store_Units.ID = this.ID + "_store";
            base.OnInit(e);
        }
    
    
        public string ICategory
        {
            get
            {
                if (this.store_Units.Parameters["ICategory"] != null)
                {
                    return this.store_Units.Parameters.GetParameter("ICategory").Value.ToString();
                }
                else
                {
                    return "";
                }
            }
            set
            {
                this.store_Units.Parameters.Add(new Ext.Net.Parameter("ICategory", value.ToString(), ParameterMode.Raw));
            }
        }
    
    
        public int UserId
        {
            get
            {
                if (this.store_Units.Parameters["UserId"] != null)
                {
                    return int.Parse(this.store_Units.Parameters.GetParameter("UserId").Value);
                }
                else
                {
                    return -1;
                }
            }
            set
            {
                this.store_Units.Parameters.Add(new Ext.Net.Parameter("UserId", value.ToString()));
            }
        }
    
    
        public string Url
        {
            get
            {
                return (this.store_Units.Proxy.Primary as AjaxProxy).Url;
            }
            set
            {
                (this.store_Units.Proxy.Primary as AjaxProxy).Url = value;
            }
        }
        public string StoreId
        {
            get
            {
                return this.store_Units.ID;
            }
        }
    </script>
    <ext:Store ID="store_Units" runat="server" IDMode="Static" RemoteSort="true" AutoLoad="false"
        PageSize="24">
        <Proxy>
            <ext:AjaxProxy Json="true">
                <Reader>
                    <ext:JsonReader Root="rows" IDProperty="ID" />
                </Reader>
            </ext:AjaxProxy>
        </Proxy>
        <Model>
            <ext:Model ID="Model_Units" runat="server">
                <Fields>
                    <ext:ModelField Name="ID" Type="Int" SortDir="ASC" />
                    <ext:ModelField Name="Name" Type="String" />
                    <ext:ModelField Name="Model" Type="String" />
                    <ext:ModelField Name="SerialNo" Type="String" />
                    <ext:ModelField Name="WarantyExpireDateTime" Type="Date" DateFormat="M$" />
                    <ext:ModelField Name="UnitExpireDate" Type="Date" DateFormat="M$" />
                    <ext:ModelField Name="Quantity" Type="Int" />
                    <ext:ModelField Name="Manufacturer" Type="String" />
                    <ext:ModelField Name="UnitsStatusID" Type="String" />
                    <ext:ModelField Name="BarCode" Type="String" />
                    <ext:ModelField Name="DepartmentID" Type="String" />
                    <ext:ModelField Name="LocationID" Type="String" />
                    <ext:ModelField Name="ServiceAgreemnetID" Type="String" />
                    <ext:ModelField Name="UserID" Type="Int" DefaultValue="-1" />
                    <ext:ModelField Name="UnitCategoryName" Type="String" />
                    <ext:ModelField Name="UnitCategoriesID" Type="Int" />
                    <%--<ext:ModelField Name="VenderId" Type="Int" />--%>
                    <ext:ModelField Name="Description" Type="String" />
                    <ext:ModelField Name="LockUnit" Type="Boolean" />
                    <ext:ModelField Name="VenderName" Type="String" />
                    <ext:ModelField Name="PurchaseDate" Type="Date" DateFormat="M$" />
                    <ext:ModelField Name="CreatedBy" Type="String" />
                    <ext:ModelField Name="CreatedDate" Type="Date" DateFormat="M$" />
                    <ext:ModelField Name="DepartmentName" Type="String" />
                    <ext:ModelField Name="StatusName" Type="String" />
                    <ext:ModelField Name="LocationName" Type="String" />
                    <ext:ModelField Name="DeletedBy" Type="String" />
                    <ext:ModelField Name="DeletedDateTime" Type="Date" DateFormat="M$" />
                    <%-- <ext:ModelField Name="Update" Type="Boolean" />
                    <ext:ModelField Name="Delete" Type="Boolean" />
                    <ext:ModelField Name="Create" Type="Boolean" />--%>
                </Fields>
            </ext:Model>
        </Model>
        <Parameters>
            <ext:StoreParameter Name="limit" Value="24" Mode="Raw" />
            <ext:StoreParameter Name="start" Value="0" Mode="Raw" />
            <ext:StoreParameter Name="dir" Value="ASC" />
            <ext:StoreParameter Name="sort" Value="ID" />
            <ext:StoreParameter Name="gridfilters" />
        </Parameters>
    </ext:Store>

    Click image for larger version. 

Name:	UnitStore.PNG 
Views:	10 
Size:	59.0 KB 
ID:	7320
    Last edited by Daniil; Dec 04, 2013 at 10:48 AM. Reason: [CLOSED]
  2. #2
    Hi @jesperhp,

    Please try to use StoreParameter instead of Parameter.
    this.store_Units.Parameters.Add(new Ext.Net.StoreParameter("ICategory", value.ToString(), ParameterMode.Raw));
  3. #3
    Quote Originally Posted by Daniil View Post
    Hi @jesperhp,

    Please try to use StoreParameter instead of Parameter.
    this.store_Units.Parameters.Add(new Ext.Net.StoreParameter("ICategory", value.ToString(), ParameterMode.Raw));


    Thanks So much its working :)
    Mark as close

Similar Threads

  1. add parameter to store mvc
    By maxdiable in forum 2.x Help
    Replies: 1
    Last Post: Nov 30, 2013, 1:58 AM
  2. [CLOSED] Parameter Problem in Ext.Net
    By vijay.sahu in forum 2.x Legacy Premium Help
    Replies: 6
    Last Post: Apr 05, 2013, 11:27 AM
  3. FlashVars parameter value
    By threewonders in forum 1.x Help
    Replies: 5
    Last Post: Apr 20, 2011, 11:11 AM
  4. Return a parameter MVC
    By threewonders in forum 1.x Help
    Replies: 0
    Last Post: Mar 09, 2011, 1:24 PM
  5. Store Parameter.
    By grmontero in forum 1.x Help
    Replies: 3
    Last Post: Aug 13, 2009, 2:59 PM

Posting Permissions