Usina BRAdvPL Guide
Sign in
← All topics
FUNCTIONUnder review

ConPad1

ConPad1( [uPar1], [uPar2], [uPar3], <cConsulta>, ... ) --> lRet

Opens a standard lookup identified in SXB.

ConPad1AdvPL
01 · OVERVIEW

Overview

ConPad1 is a lookup function despite appearing as a class in some historical lists. The official custom-lookup example places the SXB name fourth and uses a logical confirmation return; that return is not field content. The old TDN page was found deleted, so this page only shows the partial invocation supported by functional documentation and public ConPad1.PRW. Further arguments and content retrieval depend on lookup and release. The example preserves SA1 position and logs no selected-customer data. (TOTVS, 2022, ref. 1; EURAI, n.d., ref. 2)

02 · SYNTAX

Syntax

ConPad1( [uPar1], [uPar2], [uPar3], <cConsulta>, ... ) --> lRet

Parameters

uPar1 / uPar2 / uPar3
AnyOptional

Positions omitted in the analyzed partial invocation.

cConsulta
CharacterRequired

SXB lookup name in the fourth position.

Return value

Logical lookup confirmation in the analyzed official example.

03 · PRACTICAL EXAMPLE

Commented example

#Include "Protheus.ch"

User Function Ed312()
    Local aArea := GetArea()
    Local aAreaSA1
    Local lConfirmed
    If Select("SA1") > 0
        aAreaSA1 := SA1->(GetArea())
        // Requires configured SA1 lookup in SXB and an interactive session.
        lConfirmed := ConPad1(,,,"SA1")
        ConOut(cValToChar(lConfirmed))
        RestArea(aAreaSA1)
    EndIf
    RestArea(aArea)
Return Nil
Expected result

Logical choice depending on interaction; not a customer code or record change. Under review: editorial example neither compiled nor run in Protheus. Check includes, release, RDD and context before testing.

BEST PRACTICES
  • Test return, cancellation and lookup-specific context. Do not copy signatures across lookups or assume lRet contains the selected field.
  • Under review: editorial example neither compiled nor run in Protheus. Check includes, release, RDD and context before testing.

Related content

REFERENCES
  1. TOTVS. ConPad1. TDN. Accessed on 2026-10-26.
  2. EURAI. ConPad1.PRW. universo_do_desenvolvedor_site, commit a5c83e9490302bdb4a0fc5a9d92c2d569a60773c. Exemplo analisado sem reprodução integral. Accessed on 2026-10-26.
Status
Under review
Page created on
Last reviewed on
Original language
Portuguese
Reviewed by
Usina.BR
0 approved comment(s)

Comments

There are no approved comments yet.

Sign in with Google or Microsoft to comment.

Powered by Usina Docs · Alpha