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.
我在 ListView 控件中有 LinkButton,我想通过单击 LinkButton 在 DataPager 中获取活动数字页面。
protected void addToCart_Click(object sender, CommandEventArgs e) { //get active number page }
请帮我。
假设您正在执行此操作,您可以执行以下操作asp.net
asp.net
protected void ListView1_PagePropertiesChanging(object sender,PagePropertiesChangingEventArgs e) { int currPage = (e.StartRowIndex / e.MaximumRows)+1; Response.Write(currPage.ToString()); }