1

我在从 C# 中的代码隐藏页面中检索 EXTJS 中组合框的 JSON 存储的 URL 部分的参数时遇到问题。以下是商店中的代码:

var ColorStore = new Ext.data.JsonStore({
    autoLoad: true,
    url: '/proxies/ReturnJSON.aspx?view=rm_colour_view',
    root: 'Rows',
    fields: ['company', 'raw_mat_col_code', 'raw_mat_col_desc']
});

以下代码在我的代码后台页面中:

protected void Page_Load(object sender, EventArgs e)
{
    string jSonString = "";
    connectionClass.connClass func = new connectionClass.connClass();
    DataTable dt = func.getDataTable("sELECT * from rm_colour_view");
    //Response.Write(Request.QueryString["view"]);
    string w = Request.Params.Get("url");
    string z = Request.Params.Get("view");
    string x = Request.Params.Get("view=");
    string c = Request.Params.Get("?view");
    string s = Request.QueryString.Get("view");
    string d = Request.Params["?view="];
    string f = Request.Form["ColorStore"];
    jSonString = Serialize(dt);
    Response.Write(jSonString);
}

该字符串w具有以下输出:

/proxies/ReturnJSON.aspx

但是,所有其他字符串都返回null

如何rm_colour_view从数据存储中检索?

4

1 回答 1

0

Try the following:

string s = Request.QueryString("view")
于 2008-12-12T11:36:12.560 回答