Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我需要ItemTemplate在我的DataList. 如何格式化页面中的方法以正确使用Eval?
ItemTemplate
DataList
Eval
该方法接受一个int作为参数。
int
<%# NumberOfEmplyeeOrders(Int32.Parse("EmployeeID"))%>
<%# NumberOfEmplyeeOrders((Int32)Eval("EmployeeID")) %>
我的演员表中有语法错误。这是正确的代码:
<%#NumberOfEmplyeeOrders((Int32)(Eval("EmployeeID"))) %>