private void FillListView(Table table, string path){
DirectoryInfo root = new DirectoryInfo(path);
DirectoryInfo[] dirs = root.GetDirectories();
TableRow row;
TableCell cell;
foreach (DirectoryInfo dir in dirs){
row = new TableRow();
cell= new TableCell();
LinkButton button = new LinkButton();
button.Text = Server.HtmlEncode(dir.Name);
button.ID = button.UniqueID;
button.CommandName= dir.Name;
button.Command += new CommandEventHandler(button_Command);
cell.Controls.Add(button);
row.Cells.Add(cell);
table.Rows.Add(row);
}
}private void button_Command(object sender, System.Web.UI.WebControls.CommandEventArgs e) {
Response.Write (e.CommandName);
}为什么不成功??没任何反应罗?请教各位高手了