Usina BRAdvPL Guide
Sign in
← All topics
FUNCTIONUnder review

AXDELETA()

AxDeleta( <cAlias>, <nReg>, <nOpc>, [cTransact], [aCpos], [aButtons], [aParam], [aAuto], [lMaximized] )

Configures record deletion in a legacy interface.

AXDELETA()AdvPL
01 · OVERVIEW

Overview

AxDeleta supplies the record deletion interface according to the Protheus dictionary. The alias must exist in SX2 with fields and validations in SX3; the caller supplies record and browse context. nOpc is the option position in aRotina. It differs from the operation code in the fourth menu column: 5 in this example. Optional argument positions differ across Ax functions; do not transfer AxAltera positions to AxInclui or AxDeleta. The page does not formalize a return. The fragment only configures an option in an already prepared legacy routine without executing the operation. (TOTVS, n.d., ref. 1)

02 · SYNTAX

Syntax

AxDeleta( <cAlias>, <nReg>, <nOpc>, [cTransact], [aCpos], [aButtons], [aParam], [aAuto], [lMaximized] )

Parameters

cAlias
CharacterRequired

Alias registered in SX2 and available in context.

nReg
NumericRequired

Record RecNo in browse context.

nOpc
NumericRequired

Option position in aRotina, not a universal operation code.

cTransact
CharacterOptional

Function called inside the AxFunction transaction.

aCpos
ArrayOptional

Editable fields; in AxDeleta, displayed fields.

aButtons
ArrayOptional

Additional buttons: bitmap, block and title.

aParam
ArrayOptional

Functions before the screen, validation, inside and outside the transaction, in that order.

aAuto
ArrayOptional

Automatic-mode fields, values and validations; requires separate analysis.

lMaximized
LogicalOptional

Dialog maximization.

Return value

The consulted page does not specify a return contract; the example does not use it.

03 · PRACTICAL EXAMPLE

Commented example

// Fragment: aRotina already exists in the legacy caller.
// The framework supplies alias, record and option position.
AAdd(aRotina, {"Deletion", "AxDeleta", 0, 5})
Expected result

Adds one menu entry; it does not independently open a screen or modify data. Under review: editorial example neither compiled nor run in Protheus. Check includes, release, RDD and context before testing.

BEST PRACTICES
  • Test on a custom test table with permissions and validation. Generic functions do not replace complete business-routine rules or an MVC design.
  • Under review: editorial example neither compiled nor run in Protheus. Check includes, release, RDD and context before testing.

Related content

REFERENCES
  1. TOTVS. AXDELETA(). TDN. Contrato da função e exemplo aRotina. 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