Cascading DropDownLists With ASP.NET and jQuery
Cascading drop down lists is a really nice feature for web developers. I thought it was time to write an article on how to do this using ASP.NET and jQuery. Well here’s one way of doing it. Before we get started, this example uses the latest version of jQuery which is 1.3.2. That can be downloaded from here.
Open Visual Studio 2008 and create a new Web Application. For this article I’m not going to connect to a database. I’ve created two classes, Employee and EmployeeCars, which will store the data. Create two new classes and add the following code:
C#
public class Employee
{
public int Id { get; set; }
public string GivenName { get; set; }
public string Surname { get; set; }
public List<Employee> FetchEmployees()
{
return new List<Employee>
{
new Employee {Id = 1, GivenName = "Tom", Surname = "Hanks"},
new Employee {Id = 2, GivenName = "Tiger", Surname = "Woods"},
&nb
相关文档:
1. JS中取得Asp.Net的值
(1)取得服务端控件的值
var s = document.getElementById("TextBox1").value; //取得TextBox1的Text值
(2)取得全局变量的值
在Page_Load()方法前定义protected String sT;
在Page_Load()方法中赋值sT = "哈哈";
JS中这样写取得
var s = "<%=sT %>";
-------------------- ......
public static string TheColor(string color,string enumName)
{
return string.Format("<span style=\"color={0}\">{1}</span>",color,enumName);
  ......
今天在实现如题内容时,始终出现了一些问题,在论坛留言,回复者甚多,但也良莠不齐,遂在痛苦煎熬的整理后,生出此文
本文仅为一种GridView+CheckBox实现全选/反选/删除的方法,仅供大家参考,欢迎大家提出自己宝贵意见
demo.aspx页面
<!-- 略-->
<asp:GridView id="GvContent" runat="server" &g ......
Here is the full list of all events that occur in an ASP.NET application, from the standard modules, to the page, master page, page controls and master page controls.
I have not included the IIS 7 specific events (Log, for example).
What
When
HttpApplication.BeginRequest
HttpApplication.Auth ......