1. 程式人生 > >Asp.net 2.0 Treeview 動態填充,並實現無限級樹

Asp.net 2.0 Treeview 動態填充,並實現無限級樹

{
      
       
//hooyesDataLink 為配置中資料連線字串鍵名
        SqlConnection con =new SqlConnection(ConfigurationManager.AppSettings["hooyesDataLink"]);
        SqlDataAdapter sda
=new SqlDataAdapter("select * from table1", con);
        DataTable dt
=new DataTable();
        sda.Fill(dt);
       
return dt;
    }