Avalados por :

Exclusão de linhas de tabela UDO documento através do objeto DI: É possível cancelar uma linha?

  • Creado 01/03/2024
  • Modificado 01/03/2024
  • 1 Vistas
0
Cargando...

É possível excluir ou cancelar uma linha de uma tabela de documento UDO através do objeto DI?

Pedro Pascal
Se unió el 07/03/2018
Pinterest
Telegram
Linkedin
Whatsapp

4 Respuestas

0
Cargando...

Muito obrigado.

Respondido el 15/04/2024
LUCIANO RIOJA GHIOTTO
Se unió el 13/07/2019
0
Cargando...

Sergio,

Instantiate the UDO you need to work with


        Dim oCompanyService As SAPbobsCOM.CompanyService = oCompany.GetCompanyService
        Dim oGeneralService As SAPbobsCOM.GeneralService = oCompanyService.GetGeneralService("TABLE_HEADER")
        Dim oGeneralData As SAPbobsCOM.GeneralData = oGeneralService.GetDataInterface(SAPbobsCOM.GeneralServiceDataInterfaces.gsGeneralData)
        Dim oGeneralChildren As SAPbobsCOM.GeneralDataCollection
        Dim oGeneralParams As SAPbobsCOM.GeneralDataParams = oGeneralService.GetDataInterface(SAPbobsCOM.GeneralServiceDataInterfaces.gsGeneralDataParams)

...
                    oGeneralParams.SetProperty("DocEntry", "100001")  ' 100001 is the document number
                    oGeneralData = oGeneralService.GetByParams(oGeneralParams) 'Retrieve the object to memory
                    oGeneralChildren = oGeneralData.Child("TABLE_ROWS")
                    For i As Integer = 1 To oGeneralChildren.Count
                        oGeneralChildren.Remove(0) ' Remove all the rows.
                    Next
                    oGeneralService.Update(oGeneralData) 'Update the object.
...

Regards,

Vítor Vieira

Respondido el 15/04/2024
LUCIANO RIOJA GHIOTTO
Se unió el 13/07/2019
0
Cargando...

Olá, você pode me enviar um exemplo para que eu possa replicá-lo? Estou um pouco perdido.

Respondido el 15/04/2024
LUCIANO RIOJA GHIOTTO
Se unió el 13/07/2019
0
Cargando...

Olá Sergio,

Este é um fórum em inglês.

Sim, é possível. Você tem exemplos no arquivo de ajuda do SDK.

Saudações,

Vítor Vieira

Respondido el 15/04/2024
LUCIANO RIOJA GHIOTTO
Se unió el 13/07/2019

contacto@primeinstitute.com

(+51) 1641 9379
(+57) 1489 6964

© 2024 Copyright. Todos los derechos reservados.

Desarrollado por Prime Institute

¡Hola! Soy Diana, asesora académica de Prime Institute, indícame en que curso estas interesado, saludos!
Hola ¿Puedo ayudarte?