我在学习教程,然后想扩展知道一下代码返回的是什么数据类型
Label UnitPriceLabel = (Label)e.Item.FindControl("UnitPriceLabel");
Response.Write(e.Item.FindControl("UnitPriceLabel").GetType());打印出来的类型是System.Web.UI.WebControls.LabelSystem 不太理解FindControl这个方法的运行机制。
Label UnitPriceLabel = (Label)e.Item.FindControl("UnitPriceLabel");
Response.Write(e.Item.FindControl("UnitPriceLabel").GetType());打印出来的类型是System.Web.UI.WebControls.LabelSystem 不太理解FindControl这个方法的运行机制。
当然就是Label了 不然还能是什么?
GetType得到的是类型的完全限定名