nRow, nColRow and column where the panel is placed inside its parent.
AdvPL Guide@ <nRow>, <nCol> MSPANEL <oPanel> [PROMPT <cPrompt>] [OF <oWnd>] [FONT <oFont>] [CENTERED] [COLORS <nClrText>, <nClrBack>] [SIZE <nWidth>, <nHeight>] [LOWERED | RAISED]Creates a TPanel container that organizes and hosts other visual components.
The @ ... MSPANEL command creates a grouping panel that may be the parent of SAY, GET, BUTTON and other controls. During compilation it is translated into the TPanel class New() constructor. Unlike TGroup, which only draws a frame, the panel is a real container and establishes a new positioning area for child components.
@ <nRow>, <nCol> MSPANEL <oPanel> [PROMPT <cPrompt>] [OF <oWnd>] [FONT <oFont>] [CENTERED] [COLORS <nClrText>, <nClrBack>] [SIZE <nWidth>, <nHeight>] [LOWERED | RAISED]nRow, nColRow and column where the panel is placed inside its parent.
oPanelVariable that receives the created TPanel object.
PROMPT / VAR cPromptTitle displayed in the inner panel area.
OF oWndDialog, panel or other container that owns the new panel. OF is recommended.
FONT oFontDifferent font used as the default by inner components.
CENTERED / CENTERCenters the panel title; by default it appears at the upper-left of the inner area.
COLOR / COLORS nClrText, nClrBackText color and, optionally, panel background color.
SIZE nWidth, nHeightPanel width and height; define them during or after creation.
LOWEREDDraws right and bottom borders for a lowered appearance.
RAISEDDraws left and top borders for a raised appearance.
#Include "TOTVS.ch"
User Function ExMsPanel()
Local oDlg
Local oPanel
Local cName := Space(40)
Local lActive := .T.
Define Dialog oDlg Title "Registration" ;
From 100, 100 To 340, 600 Pixel
@ 10, 15 MsPanel oPanel Prompt "Main data" ;
Colors CLR_BLACK, CLR_HGRAY Size 250, 90 ;
Of oDlg Raised
@ 20, 15 Say "Name:" Of oPanel Pixel
@ 18, 60 Get cName Size 150, 12 Of oPanel Pixel
@ 50, 15 CheckBox lActive Prompt "Active record" ;
Size 100, 15 Of oPanel Pixel
Activate Dialog oDlg Centered
ReturnSAY, GET and CHECKBOX belong to oPanel and are positioned within its area.
#Include "TOTVS.ch"
User Function ExPanelBordas()
Local oDlg
Local oSuperior
Local oInferior
Define Dialog oDlg Title "Áreas da tela" ;
From 0, 0 To 300, 520 Pixel
@ 10, 15 MsPanel oSuperior Prompt "Resumo" ;
Size 220, 45 Of oDlg Raised
@ 10, 10 Say "Conteúdo em destaque" ;
Of oSuperior Pixel
@ 70, 15 MsPanel oInferior Prompt "Detalhes" ;
Size 220, 55 Of oDlg Lowered
@ 10, 10 Say "Conteúdo detalhado" ;
Of oInferior Pixel
Activate Dialog oDlg Centered
ReturnRAISED and LOWERED visually distinguish areas while keeping controls in their respective containers.
© 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.