nRow, nColRow and column where the folder is placed. With PIXEL, coordinates start at the upper-left corner of the parent.
AdvPL Guide@ <nRow>, <nCol> FOLDER <oFolder> [OF <oWnd>] [PROMPTS <cItem,...>] [OPTION <nOption>] [SIZE <nWidth>, <nHeight>] [PIXEL]Creates a tabbed TFolder container for organizing visual components in one interface.
The @ ... FOLDER command creates a grouping component with one or more tabs. During compilation it is translated into the TFolder class New() constructor. Tabs may be declared with PROMPT, PROMPTS or ITEMS, or added later with AddItem(). Each inner area is available through oFolder:aDialogs so different controls can be created on each tab.
@ <nRow>, <nCol> FOLDER <oFolder> [OF <oWnd>] [PROMPTS <cItem,...>] [OPTION <nOption>] [SIZE <nWidth>, <nHeight>] [PIXEL]nRow, nColRow and column where the folder is placed. With PIXEL, coordinates start at the upper-left corner of the parent.
oFolderVariable that receives the created TFolder object.
OF oWndDialog, panel or other container that owns the folder. OF is recommended.
PROMPT / PROMPTS / ITEMSTab titles. The supplied expressions are internally treated as an array.
OPTION nOptionNumber of the tab initially selected.
SIZE nWidth, nHeightComponent width and height; define them during or after creation for correct display.
COLOR nClrTextText color used by the component.
MESSAGE cMsgContextual hint displayed while the pointer remains over the component.
PIXELIndicates that position and size use pixel coordinates.
#Include "TOTVS.ch"
User Function ExFolderPrompts()
Local oDlg
Local oFolder
Local cName := Space(40)
Local lActive := .T.
Define Dialog oDlg Title "Registration" ;
From 0, 0 To 360, 620 Pixel
@ 10, 15 Folder oFolder ;
Prompts "General", "Preferences" ;
Option 1 Size 270, 140 Of oDlg Pixel
@ 15, 15 Say "Name:" Of oFolder:aDialogs[1] Pixel
@ 13, 55 Get cName Size 150, 10 ;
Of oFolder:aDialogs[1] Pixel
@ 15, 15 CheckBox lActive Prompt "Active record" ;
Size 100, 15 Of oFolder:aDialogs[2] Pixel
Activate Dialog oDlg Centered
ReturnPROMPTS creates two tabs. SAY and GET belong to the first; CHECKBOX belongs to the second through aDialogs.
#Include "TOTVS.ch"
User Function ExFolderDinamico()
Local oDlg
Local oFolder
Define Dialog oDlg Title "Consulta" ;
From 0, 0 To 320, 560 Pixel
@ 10, 15 Folder oFolder Size 240, 120 ;
Of oDlg Pixel
oFolder:AddItem("Resumo", .T.)
oFolder:AddItem("Detalhes", .T.)
@ 10, 10 Say "Visão resumida" ;
Of oFolder:aDialogs[1] Pixel
@ 10, 10 Say "Informações detalhadas" ;
Of oFolder:aDialogs[2] Pixel
oFolder:SetOption(1)
Activate Dialog oDlg Centered
ReturnAddItem() creates tabs after the component and SetOption(1) selects the first.
© 2026 Usina.BR. Todos os direitos reservados. TOTVS, Protheus, Microsiga e seus respectivos logotipos são marcas de titularidade da TOTVS S.A. AdvPL é uma linguagem de programação desenvolvida pela TOTVS. O AdvPL Guia é um projeto independente, sem vínculo, representação, patrocínio ou afiliação com a TOTVS S.A., suas franquias ou representantes.