cancel
Showing results for 
Search instead for 
Did you mean: 

Simulate the behavior of search with '*' character

Former Member
0 Kudos

I need to simulate the behavior of column 1 of Item 76(Matrix) of form 392 (JE). In other words i need to associate an account search to a field in a form created by me. When I select the account that I wish, the field is filled with that value.

I only find 'Formatted search' topics in forum. I don't wish formatted search, because the add-on must be full automatic. The user don't need to do anything, don´t need to configure nothing.

Can I simulate that?

Thanks to all,

Best regards

Ricardo Pereira

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Ricardo,

To simulate this behaviour, you will need to capture the appropriate events from the grid column/edit text/object you are working with. On the ItemEvent you will need to validate the value of your object on the et_VALIDATE event(when the user tabs off your object) and/or on the et_KEY_DOWN event (when the user presses the Enter key).

You will need to create your own account search screen, as you currently can't use the standard SBO search screens.

For example:

public override void ItemEvent(string FormUID, ref SAPbouiCOM.ItemEvent pVal, out bool BubbleEvent)

{

BubbleEvent = true;

if ((pVal.Before_Action == false) && (FormUID == form.UniqueID))

{

switch(pVal.EventType)

{

if (pVal.ItemUID == "EdCust")

{

if ((pVal.CharPressed == TAB) ||(pVal.CharPressed == ENTER))

{

if (!Utilities.ValidCustomer(EdAccNo.Value))

ShowCustomerSearchForm(EdAccNo.String);

else if (PrevCardCode != EdAccNo.Value)

{

EdAccName.Value = Utilities.GetBusinessPartnerName(EdAccNo.Value);

}

}

}

}

}