cancel
Showing results for 
Search instead for 
Did you mean: 

Issue With adding a New Child to Existing UDO

Former Member
0 Kudos

Hi All

         Can we add a new child to existing UDO?

         If yes how can we Update the existing UDO programmaticall

Accepted Solutions (1)

Accepted Solutions (1)

former_member185682
Active Contributor
0 Kudos

Hi Sheetal,

Try this:


            UserObjectsMD oUserObjectMd = oCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oUserObjectsMD);

            if (oUserObjectMd.GetByKey("your object id"))

            {

                //made your changes

                //Open a new child

                oUserObjectMd.ChildTables.Add();

                //Sets your child table

                //oUserObjectMd.ChildTables.TableName = "Test"

                if (oUserObjectMd.Update() != 0)

                    MessageBox.Show("Something wrong. Error: " + oCompany.GetLastErrorDescription());

            }

Hope it helps.


Best regards,

Diego Lother


View Diego Lother's profile on LinkedIn

Former Member
0 Kudos

Hi Diego

Thank You. It Worked.

Regards,

Sheetal H

Answers (0)