Hello Janusz,
Please review our answer to a similar question in the Support Center:
Is there a way to turn off lazy loading in the XtraTabControl?
Thanks,
Nick
--------------------
Check if Search Engine is able to answer questions faster than I do!
-
Something is clarified in article that You linked me to. But question still stands:
How to force XtraTabPage to load all Edit Values at form Loading?Hello Janusz,
To force data binding at the form load stage, iterate through tab pages and activate them. I'm sending you a sample project.
Thanks,
Nick
--------------------
Check if Search Engine is able to answer questions faster than I do!Thanks for help. Problem solved.
We found that changing SelectedTabPageIndex doesn't work at all. Below is a version that does work:
[C#]protected XtraTabControl FixDataBinding { get; set; } private void EditFormUserControl_VisibleChanged(object sender, EventArgs e) { if (FixDataBinding != null) { // https://www.devexpress.com/Support/Center/Question/Details/Q259067/edit-value-not-loaded-until-component-tab-page-is-visible // bind data on invisible tabs var initialTab = FixDataBinding.SelectedTabPage; foreach (XtraTabPage t in FixDataBinding.TabPages) { t.Show(); } initialTab.Show(); } }
Subclasses will assign their tab control to FixDataBinding in their constructor.
Hello Yuntian,
To process your recent post in the most efficient manner, I've created a separate ticket on your behalf: XtraTabControl - Setting the SelectedTabPageIndex property doesn't change an active tab. I will address it shortly.