小编R B*_*R B的帖子

从动态财产中获取价值

d.GetType().GetProperty("value2").GetValue(d, null);
Run Code Online (Sandbox Code Playgroud)

这将返回d中value2属性的值.

我想要value2中的属性值,即d.value2.value3.

我该怎么做到这一点?

c#

3
推荐指数
1
解决办法
9158
查看次数

未捕获的引用错误:未定义False

我有以下对javascript的调用:

protected override void OnPreRender(EventArgs e)
    {
        base.OnPreRender(e);

        this._BtAdd.Attributes.Add("onclick", "GXDualListBox_MoveDualList(" + sourceListId + ",  " + destListId + ",  " + selectedValuesId + ", false, true, "+ this._SortByDescription +");");
        this._BtRemove.Attributes.Add("onclick", "GXDualListBox_MoveDualList(" + destListId + ",  " + sourceListId + ",  " + selectedValuesId + ", false, false, " + this._SortByDescription + ");");

        if (!this._PostBackOnAll)
        {
            this._BtAddAll.Attributes.Add("onclick", "GXDualListBox_MoveDualList(" + sourceListId + ",  " + destListId + ",  " + selectedValuesId + ", true, true, " + this._SortByDescription + " );");
            this._BtRemoveAll.Attributes.Add("onclick", …
Run Code Online (Sandbox Code Playgroud)

javascript c# asp.net

3
推荐指数
1
解决办法
1万
查看次数

JQuery/Ajax 返回 Success 消息并显示 Saved 指示器

这是我第一次尝试使用 JQuery/Ajax。我有一个 RadDatePicker,在选择日期时,日期保存在数据库中,用户应该收到一条消息,说明日期已保存。RadDatePicker 在其事件 OnDateSelected 上调用一个函数,如下所示(C#):

  radDatePicker.ClientEvents.OnDateSelected = "function(sender, args){SaveDate(sender,args," + PriceDealProposalId + ")}";
Run Code Online (Sandbox Code Playgroud)

javascript 函数 SaveDate 成功调用网络服务来保存所选日期。

   function SaveDate(sender, e, id) {       
       if (e.get_newDate() != null) {
           $.ajax({
               url: "/ajaxservice.asmx/SaveSignedDate",
               data: "{priceDealProposalId:" + id + ",proposalDate: " + JSON.stringify(e.get_newDate()) + "}",
               dataType: "json",
               type: "POST",
               contentType: "application/json;charset=utf-8",
               success: function (data) {
                   alert("saved");
               }
           });
       }
   }
Run Code Online (Sandbox Code Playgroud)

以上成功保存值并提示消息。我想在此 RadDatePicker 控件附近显示一条文本消息,而不是警报,该消息显示“已保存”并在几秒钟内消失。我不确定如何解释此成功消息并显示文本。请帮我。

ajax jquery web-services telerik raddatepicker

3
推荐指数
2
解决办法
4万
查看次数

标签 统计

c# ×2

ajax ×1

asp.net ×1

javascript ×1

jquery ×1

raddatepicker ×1

telerik ×1

web-services ×1