Usina BRAdvPL Guide
Sign in
← All topics
FUNCTIONUnder review

GetHlpSoluc

GetHlpSoluc(cCampo) -> aHelp (community subset)

Retrieves a field help’s problem and solution texts.

GetHlpSolucAdvPL
01 · OVERVIEW

Overview

The public Terminal de Informação example uses return positions 1 and 2 in a GET bHelp. This community subset does not guarantee structure on every release. The example queries once and checks array type and length before accessing both positions; the field help must be available in the environment. (Sources: refs. 1–1.)

02 · SYNTAX

Syntax

GetHlpSoluc(cCampo) -> aHelp (community subset)

Parameters

cCampo
CharacterRequired

Field with registered help.

03 · PRACTICAL EXAMPLE

Commented example

#Include "Protheus.ch"

User Function Ed468()
    Local aHelp := GetHlpSoluc("B1_COD")
    // Validate return before indexing.
    If ValType(aHelp) == "A"
        If Len(aHelp) >= 2
            ConOut(cValToChar(aHelp[1]))
            ConOut(cValToChar(aHelp[2]))
        EndIf
    EndIf
Return Nil
Expected result

Shows available texts without assuming language or completeness. Under review: editorial example neither compiled nor run in Protheus. Check includes, release, RDD and context before testing.

BEST PRACTICES
  • For GET use, integrate with the appropriate callback and retain field and language context.
  • Under review: editorial example neither compiled nor run in Protheus. Check includes, release, RDD and context before testing.

Related content

REFERENCES
  1. Daniel Atilio. Como colocar um help em um Get customizado em AdvPL. Terminal de Informação, 2015.
  2. Daniel Atilio. zExempF1.prw; commit 7d275a7.
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