cancel
Showing results for 
Search instead for 
Did you mean: 

How to Handle Yes in Addon Screen

former_member296240
Participant
0 Kudos

Hi All,

I am posting po when i click add button but When i Click Close button in my addon screen then sap through this message box .when i click Yes

then Document is added but transaction is not happened .how do i rectify this  how do i get this event.

Accepted Solutions (1)

Accepted Solutions (1)

ANKIT_CHAUHAN
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi Jaba,

You need to handle the Data_Event. In Data_Event you need to handle the Form_Data_Add Event.

Hope it helps.

Thanks & Regards

Ankit Chauhan

SAP Business One Global Support

former_member296240
Participant
0 Kudos

thanks for your reply

Do you have any sample code for this.

ANKIT_CHAUHAN
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi Jaba,

You need to have a look at the SDK Help Center for more details and samples. Here is what I have found there:

void B1Application_FormDataEvent(ref SAPbouiCOM.BusinessObjectInfo BusinessObjectInfo, out bool BubbleEvent)

{

    BubbleEvent = true;

    if(BusinessObjectInfo.BeforeAction)

    {

        String key1 = BusinessObjectInfo.ObjectKey;

        // The String contains XML with the key, also in UDOs

        MessageBox.Show("Key Information in before event: " + key1);

    }

    else

    {

        String key2 = BusinessObjectInfo.ObjectKey;

        // The String contains XML with the key, also in UDOs

        MessageBox.Show("Key Information in after event: " + key2);

    }

}

Hope it helps.

Thanks & Regards

Ankit Chauhan

SAP Business One Global Support

Answers (1)

Answers (1)

former_member296240
Participant
0 Kudos