0

ContinueClick コードでは、「コントロールはページのコントロール ツリー
にある必要があります。パラメータ名: コントロール」というエラーが表示されます。

$('#' + btnContinueClientID).click(function () 
{
ToShowAlertMessage()
}

function ToShowAlertMessage(controlName, segmentID, passengerID) {
        $.post("/JQuerySeatMap.aspx",
    { ClickedControl: controlName,
        str1: str1,
        str2: str2,
            str3: str3
    },

public string ContinueClick(string str1, string str2, string str3)
{
ScriptManager.RegisterStartupScript(this, GetType(), "ClientScript", "alert('Alert   
 Message.');, true);
}


But in the ContinueClick code it gives an error "The control must be in the control tree    
of a page. Parameter name: control"
4

1 に答える 1

0

これを行うより良い方法は、 を登録してクライアント側コードを呼び出すalertのではなく、 を JS コールバック内に配置することです。ScriptManager

$.post("/JQuerySeatMap.aspx",
{ ClickedControl: controlName,
    str1: str1,
    str2: str2,
    str3: str3
}, function(data) {
    alert('Alert Message.');
});
于 2013-09-27T13:53:02.633 に答える