Skip to Content
author's profile photo Former Member
Former Member

Employee Code Value

hi

As i move from 1 record to another i want to display Employee ID value in a message box.

Thanks

Add a comment
10|10000 characters needed characters exceeded

Related questions

2 Answers

  • Best Answer
    Posted on Nov 08, 2012 at 01:17 AM

    Hi Sunny,

    The best to do this is you catch the After Form Data Load event.

    In this event, the screen is already populated with the data, so you can easily get the value from the Edit Text of ItemUID 33.

    Do note that Form Data event has its own event handler method. Not the same as Item Event.

    This event falls under this method :

        Private Sub SBO_Application_FormDataEvent(ByRef BusinessObjectInfo As SAPbouiCOM.BusinessObjectInfo, ByRef BubbleEvent As Boolean) Handles SBO_Application.FormDataEvent          'Your codes here    End Sub

    The logic is:

    1. Catch After Form Data Load event.

    2. Get the Edit Text of Item UID '33'

    3. Get the value of this edittext and pop up the message box.

    Try it out, if you have any problem let us know.

    Regards

    Edy

    Add a comment
    10|10000 characters needed characters exceeded

    • Hi Sunny,

      You missed a few things.

      1. BusinessObjectInfo does not have BusinessObjectInfo.Before_Action property. Instead, use BusinessObjectInfo.BeforeAction.

      2. You should catch it on BeforeAction = False.

      3. BusinessObjectInfo does not have BusinessObjectInfo.FormTypeCount property. use this line instead :

      oForm = Me.SBO_Application.Forms.Item(BusinessObjectInfo.FormUID)

      The rest should be okay.

      This is the complete code :

          Private Sub SBO_Application_FormDataEvent(ByRef BusinessObjectInfo As SAPbouiCOM.BusinessObjectInfo, ByRef BubbleEvent As Boolean) Handles SBO_Application.FormDataEvent        SBO_Application.MessageBox("in")        If ((BusinessObjectInfo.FormTypeEx = "60100" And BusinessObjectInfo.EventType = SAPbouiCOM.BoEventTypes.et_FORM_DATA_LOAD) And (BusinessObjectInfo.BeforeAction = False)) Then            Dim oForm As SAPbouiCOM.Form = Me.SBO_Application.Forms.Item(BusinessObjectInfo.FormUID)            SBO_Application.MessageBox(oForm.Items.Item("33").Specific.value.ToString())            SBO_Application.MessageBox("in")        End If    End Sub

      Regards

      Edy

  • author's profile photo Former Member
    Former Member
    Posted on Nov 08, 2012 at 12:55 AM

    Hi Sunny,

    Can you post your code please?

    Regards,

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.