Call C#.net method in Javascript
<p>I Have Method in Code behind(C#) and Want to call this method inside the javascript.</p>

<p>My Code in C#</p>

<pre><code>    private void StatusSet()
    {            
        List&lt;StatusHandler&gt; iListStatus = new List&lt;StatusHandler&gt;();

        iListStatus.Add(new StatusHandler('A', "Active"));
        iListStatus.Add(new StatusHandler('I', "InActive"));
        iListStatus.Add(new StatusHandler('L', "All"));

        if (hdnMode.Value == "i")
        {
            ddlStatus.DataSource = iListStatus.Take(2);
        }
        else
        {
            ddlStatus.DataSource = iListStatus.Take(3);
            if (lnkBtnUpdate1.Visible == true)
            {
                ddlStatus.DataSource = iListStatus.Take(2);
            }
        }
    }
</code></pre>

<p>Javascript :</p>

<pre><code>function GetMode(modeIndex) {
    if (modeIndex == 'i') {
        StatusSet(); //How to Call in Javascript
    }
}
</code></pre>
