Now it is possible to decide during runtime if some pages will be added or not to a tab control depending on the nature of the data or specific data values you have.
And furthermore, you may also dynamically populate such pages with any GUI controls you need.
In this sense, if for instance you declare a tab control on the screen section like this:
03 Tb1-container tab-control line 5 col 2 lines 17 cells size 68 cells allow-container .The statement to add pages dynamically is like the following:
modify Tb1-container tab-to-add ("page1", "page2")Now, in order to add dynamic controls to each new page, it is important to remember that every tab page is indexed by an incremental integer number.
display label line 8 col 4 title label-title upon Tb1-Container(t1-next-page) display entry-field line 10 col 4 upon Tb1-Container(t1-next-page)You may download a complete sample program that demonstrates this functionality.
iscc -sp="%iscobol%sampleisdef" dyntab.cblRun it like this:
iscrun DYNTAB
Article ID: 308
Created: November 28, 2019
Last Updated: November 28, 2019
Author: Support KB Author
Online URL: https://support.veryant.com/phpkb/article.php?id=308