Usina BRAdvPL Guide
Sign in
← All topics
FUNCTIONUnder review

ALERT()

Alert( <cTexto> )

Displays a simple message in an interactive session.

ALERT()AdvPL
01 · OVERVIEW

Overview

The official ALERT() page documents displaying text without establishing a business-confirmation contract. Use a short informational message; if the application requires a choice, select a function with a documented return and handle it explicitly. Do not import arguments from other APIs named Alert. (TOTVS, n.d., ref. 1)

02 · SYNTAX

Syntax

Alert( <cTexto> )

Parameters

cTexto
CharacterRequired

Text presented to the user.

Return value

Not specified in the consulted page; the example ignores the return.

03 · PRACTICAL EXAMPLE

Commented example

#Include "Protheus.ch"

User Function EdAlert()
    // Information without a decision or data write.
    Alert("Check completed; no data was changed.")
Return Nil
Expected result

Proposes displaying one message. Under review: editorial example neither compiled nor run in Protheus. Check includes, release, RDD and context before testing.

BEST PRACTICES
  • Do not use dialogs in jobs, REST or noninteractive processing. Closing a message does not authorize writing.
  • Under review: editorial example neither compiled nor run in Protheus. Check includes, release, RDD and context before testing.

Related content

REFERENCES
  1. TOTVS. ALERT(). TDN. Accessed on 2026-10-25.
  2. SANTOS, Milton J. dos. Alertas.prw, 2020. Repositório rogeriosacra/ADVPL, ETHIOS/Aula 01 - Alertas001/Aula 01 - Alertas/Alertas.prw. Commit a10ba66270cd96ec062c3ad54547a0145b8b29b8. Exemplo comunitário analisado, sem reprodução integral. Accessed on 2026-10-25.
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