使用参数从javascript调用codebehind函数

使用参数从javascript调用codebehind函数,javascript,c#,jquery,asp.net,kendo-ui,Javascript,C#,Jquery,Asp.net,Kendo Ui,我需要使用参数调用codebehind函数,该参数是aspx页面中脚本标记中某个实体类的实例。Im使用kendotemplate从剑道ui创建弹出窗口,在此模板中,我需要在代码隐藏中使用带有输入和按钮的表单。类似这样的东西,但当我将asp项目添加到模板标记时,这些标记对我不起作用 我的实体: public class Person { public string FirstName{ get; set; } public string LastName{ get; set; }

我需要使用参数调用codebehind函数,该参数是aspx页面中脚本标记中某个实体类的实例。Im使用kendotemplate从剑道ui创建弹出窗口,在此模板中,我需要在代码隐藏中使用带有输入和按钮的表单。类似这样的东西,但当我将asp项目添加到模板标记时,这些标记对我不起作用

我的实体:

public class Person
{
    public string FirstName{ get; set; }
    public string LastName{ get; set; }
    public int Age { get; set; }
}
代码隐藏功能:

protected void btnAddPerson_Click(object sender, EventArgs e)
    {
        Person p= new Person();
        // get values from three inputs
        p.FirstName= personFirstName.Value;
        p.LastName= personLastName.Value;
        p.Age = Convert.ToInt32(personAge.Value);
        ...
    }
在javascript中,我需要如下内容:

<script type="text/x-kendo-template" id="template">
            <Asp:Input ...>
    <Asp:Input ...>
    <Asp:Input ...>
    <Asp:Button ...>
</script>

对不起我的英语