Notifications
Selects informational, critical and confirmation messages for a workflow.
Overview
Informing differs from confirming. Alert and APMsgInfo communicate; APMsgStop does not terminate its caller; APMsgYesNo supplies a logical choice according to the historical reference and official MVC example. Choose the API for its contract rather than its icon. The community Alertas.prw example groups these calls without demonstrating transactions or authorization. This thematic guide is not a complete specification of the Aviso function. (Manual AdvPL, n.d., pp. 333–335, ref. 1; SANTOS, 2020, ref. 2; TOTVS, n.d., ref. 3)
Return value
No single return value: this is a composite workflow.
Commented example
#Include "Protheus.ch"
User Function EdAvisos()
// Test choice; no data write.
If APMsgYesNo("Review the test summary?", "Review")
APMsgInfo("Summary available for review.", "Information")
EndIf
Return NilThe informational message is requested only after confirmation; no record changes. Under review: editorial example neither compiled nor run in Protheus. Check includes, release, RDD and context before testing.
- Do not use dialogs in REST or Jobs. Test returns, closing and Escape; never put passwords or sensitive data in messages.
- Under review: editorial example neither compiled nor run in Protheus. Check includes, release, RDD and context before testing.

Comments
There are no approved comments yet.
Sign in with Google or Microsoft to comment.