web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Suggested Answer

How to customize 'finish' button on Voucher And Adjustment entry?

(0) ShareShare
ReportReport
Posted on by 5

Hi,

On form 03.010.00 (Voucher Adjustment Entry), How to customize 'finish' button on the toolbar after handling selected to 'Release Now'?

For instance i wanted to update GLTran table.

pastedimage1587717130800v1.png

I have the same question (0)
  • CFROTON Profile Picture
    4,710 on at

    Hello,

    I don't see that you can customize that button with Customization manager, perhaps someone with knowledge of VB Tools/SDK can help you in this forum. I also think that it's a global button as most process screens have 'Finish"

    Best Regards,

    Jana MacDonald

    Dynamics Support

  • Suggested answer
    Apps Mexico Profile Picture
    1,090 on at

    Hi,

    If you want to execute a process after that the batch is released you can use the OnFinish (32000) level on Update1_OnUpdate event. In other hand if you want to add a validation when the user select the Release now option you can use the _Chk event of the control, see the example that I use on 04.010.00 screen.

    Private Sub Update1_OnUpdate(Level As Integer, InsertFlg As Integer, retval As Integer)
        Select Case Level
            Case 0
                .....
            Case 1
                .....
            Case 32000
                Call ObtieneCamposLlave
                serr_xFEAPDoc = SqlFetch1(CSR_xFEAPDoc, "xsp_xFEAPDoc_All" & SParm(bxFEAPDoc.CpnyId) & SParm(bxFEAPDoc.BatNbr) & SParm(bxFEAPDoc.RefNbr) & SParm(bxFEAPDoc.DocType), txFEAPDoc, LenB(txFEAPDoc))
                If serr_xFEAPDoc = NOTFOUND Then
                    Call SInsert1(CSR_xFEAPDoc, "xFEAPDoc", bxFEAPDoc, LenB(bxFEAPDoc))
                Else
                    Call SUpdate1(CSR_xFEAPDoc, "xFEAPDoc", bxFEAPDoc, LenB(bxFEAPDoc))
                End If
        End Select
    End Sub

    Private Sub cbatchandling_Chk(ChkStrg As String, retval As Integer)
        If ChkStrg = "B" Or ChkStrg = "R" Then
            
            serr1 = MFirst(MH_POTran, MH_POTran_Flag)
            While serr1 = 0
                Call ObtieneCamposLlave
                
                serr_xAMActivoFijoValida = SqlFetch1(CSR_xAMActivoFijoValida, "xsp_xAFActivoFijo_ValidaRegistros" & SParm(vRcptNbr) & SParm(vLineRef), bxAMActivoFijoValida, LenB(bxAMActivoFijoValida))
                If serr_xAMActivoFijoValida = 0 Then
                    If bxAMActivoFijoValida.RcptQty <> bxAMActivoFijoValida.TotalRegistros Then
                        Call MessBox("El total de series registradas " & CStr(bxAMActivoFijoValida.TotalRegistros) & " , para la linea " & vLineRef & " es diferente a la cantidad recibida " & CStr(bxAMActivoFijoValida.RcptQty), MB_ICONEXCLAMATION, "ERROR")
                        retval = ErrNoMess
                        Exit Sub
                    End If
                Else
                    serr_xAFActivoFijoInfo = SqlFetch1(CSR_xAFActivoFijoInfo, "xsp_xAFActivoFijoInfo_All" & SParm(vCpnyId) & SParm(vInvtId), bxAFActivoFijoInfo, LenB(bxAFActivoFijoInfo))
                    If serr_xAFActivoFijoInfo = 0 Then
                        Call MessBox("No se han registrado las serires de los activos para la linea " & vLineRef, MB_ICONEXCLAMATION, "ERROR")
                        retval = ErrNoMess
                        Exit Sub
                    End If
                End If
                serr1 = MNext(MH_POTran, MH_POTran_Flag)
            Wend
            serr1 = MFirst(MH_POTran, MH_POTran_Flag)
        End If
    End Sub

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Congratulations to our 2025 Community Spotlights

Thanks to all of our 2025 Community Spotlight stars!

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
Giorgio Bonacorsi Profile Picture

Giorgio Bonacorsi 617

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 461 Super User 2026 Season 1

#3
Syed Haris Shah Profile Picture

Syed Haris Shah 298 Super User 2026 Season 1

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans