Usina BRAdvPL Guide
Sign in
← All topics
FUNCTIONUnder review

TEXTO()

Texto() — observed call; partial contract

Records a validation call found in official documentation.

TEXTO()AdvPL
01 · OVERVIEW

Overview

The S037 definition article shows TEXTO() as validation for DESCRICAO. This establishes a no-argument call in that context, not acceptance criteria, implicit variables or return. We infer neither arbitrary-text acceptance nor sanitization. The block is not invoked; inspect the caller and release before applying the validator elsewhere. (Sources: refs. 1–1.)

02 · SYNTAX

Syntax

Texto() — observed call; partial contract

Return value

Unconfirmed by the selected reference.

03 · PRACTICAL EXAMPLE

Commented example

#Include "Protheus.ch"

User Function Ed689()
    // Depends on field-validation context; do not invoke in isolation.
    Local bValidation := {|| Texto()}
    ConOut(ValType(bValidation))
Return Nil
Expected result

Creates block B without validating a field or assuming a .T. return. Under review: editorial example neither compiled nor run in Protheus. Check includes, release, RDD and context before testing.

BEST PRACTICES
  • Confirm implicit input, blank handling and caller return. Do not use as injection/input-security protection.
  • Under review: editorial example neither compiled nor run in Protheus. Check includes, release, RDD and context before testing.

Related content

REFERENCES
  1. TOTVS. GPEA310 — Definición de la tabla S037. Chamada TEXTO na validação; contrato não detalhado. Accessed on 2026-10-28.
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