问题描述
这可能已经被问过很多次了,但是我想知道如何维护AjaxControlToolKit TabContainer的ActiveTabIndex。
This probably has been asked many times before but I was wondering how to maintain the ActiveTabIndex of an AjaxControlToolKit TabContainer.
我想实现这一目标的唯一方法是将ActiveTabIndex存储在会话中,并在回发时进行检查。还有其他解决方案可以解决此问题吗?
The only way I can think of achieving such a thing is to store the ActiveTabIndex in the session and checking for this on postback. Are there any other solutions to solve this problem?
推荐答案
最有可能是回答了您的问题。这些东西尚未保存到页面时便属于页面的ViewState。
Most likely this answers your question. Such things belong into the ViewState of the Page when their not already saved there.
编辑:
另一方面:我已经对其进行了测试,并测试了ActiveTabIndex保持(异步)回发。
On the other hand: i've tested it and my ActiveTabIndex maintains on (asynchronous) postback.
这篇关于ASP.NET在TabContainer中回发时维护ActiveTabIndex的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!