How to add extra lines for Item Description in the list object in Picking function

  • Updated

In this example I am going to add extra lines to the Item data in the list object in the Picking function. The same technology can be used on other screens as well.

Custom fields
As a first step I will define the new data fields in the @BXPCUSTFD table.
The name of the screen can be found in the first line of the Customization Assist window.


The most important fields are the Field Name, Position Data, Data Repeater, Module

You can manage the location of the new fields in the Position Data column.
I am going to use the following data:

 

Code Name Data Repeater Field Name Field Type Label Module On External Form Position Data Protected Read Only Screen Visible
9101 9101 DataRepeater UIItemDesc1 String SplitLine BXMobileWH9 No y:20;h:80;lines:4 No No PickingLinesScreen Yes
9102 9102 DataRepeater UIItemDesc2 String SplitLine BXMobileWH9 No y:35 No No PickingLinesScreen Yes
9103 9103 DataRepeater UIItemDesc3 String SplitLine BXMobileWH9 No y:50 No No PickingLinesScreen Yes

 

This is how the fields are look like after the creation:


SQL functions

I am going to use the technique of the Manipulating DataRepeater

I am going to create a function to split the long item description into multiple columns. You can find the function for MSSQL and for HANA attached on the following names:
PMX_SplitTextIntoThreeColumns_MSSQL.sql

PMX_SPLITTEXTINTOTHREECOLUMNS_HANA.sql

The function has 2 parameters, the first one is the text and the second one is the max length of one line.

After that I am going to create the DataRepeater splitter. I am going to use a different version from that we have in the "Manipulating DataRepeater" guide.
This is because I will pass the max length of one line parameter to the TextIntoThreeColumns splitter from this function, so we can set this value later from the SAP query. And I will add extra 3 columns to the splitdata column.

You can find the function for MSSQL and for HANA attached on the following names:

SplitStringForDataRepeaterSplitText_MSSQL.sql

SPLITSTRINGFORDATAREPEATERSPLITTEXT_HANA.sql

SAP Query

The final step is to create a new SAP query. The name of the query can be found in the Customization Assist window

What we need is the InternalDataLoad event. We can manipulate the appearing data in this event.

So the name of the query must be: BXMobileWH9_PickingLinesScreen_DataRepeater_InternalDataLoad

The content of the SAP query is the following

MSSQL version
SELECT 
splitdata as [DataRepeater.UIItem],
col1 as [DataRepeater.UIItemDesc1],
col2 as [DataRepeater.UIItemDesc2],
col3 as [DataRepeater.UIItemDesc3] 
FROM SplitStringForDataRepeaterSplitText( $[DataRepeater.UIItem] , 35)
HANA version
SELECT 
"SPLITDATA" as "DataRepeater.UIItem",
"COL1" as "DataRepeater.UIItemDesc1",
"COL2" as "DataRepeater.UIItemDesc2",
"COL3" as "DataRepeater.UIItemDesc3" 
FROM SPLITSTRINGFORDATAREPEATERSPLITTEXT( $[DataRepeater.UIItem] , 35)

 

After the SAP query is added you have to restart the Produmex Scan application

 

 

 

 

Was this article helpful?

1 out of 1 found this helpful

Comments

0 comments

Please sign in to leave a comment.