21
GuiXT Solution WM-0002 Page 1 of 21 A Solution # WM-0002 Version # 1.0.0.2 Functional Area WAREHOUSE MANAGEMENT UI Platform MS Transactions MB1B, LB12, LT04, LT12 Short Description CREATE AND CONFIRM TRANSFER POSTING Date Created 05/12/2009 Created by Synactive, Inc

GuiXT Solution WM-0002 - Liquid UI - Home GuiXT Solution WM-0002 Page 1 of 21 ... In this case all variables that contain “z_mb1b” prefix get reset ... Script reads plant and storage

  • Upload
    lydan

  • View
    242

  • Download
    1

Embed Size (px)

Citation preview

Page 1: GuiXT Solution WM-0002 - Liquid UI - Home GuiXT Solution WM-0002 Page 1 of 21 ... In this case all variables that contain “z_mb1b” prefix get reset ... Script reads plant and storage

GuiXT Solution WM-0002

Page 1 of 21

So A

Solution # WM-0002 Version # 1.0.0.2 Functional Area WAREHOUSE

MANAGEMENT UI Platform MS

Transactions MB1B, LB12, LT04, LT12 Short Description CREATE AND CONFIRM TRANSFER POSTING Date Created 05/12/2009 Created by Synactive, Inc

Page 2: GuiXT Solution WM-0002 - Liquid UI - Home GuiXT Solution WM-0002 Page 1 of 21 ... In this case all variables that contain “z_mb1b” prefix get reset ... Script reads plant and storage

GuiXT Solution WM-0002

Page 2 of 21

TABLE OF CONTENTS GuiXT Development Business Rules ................................................................... 4 General Script Naming Convention...................................................................... 5

GuiXT Scripts ....................................................................................................................... 5 Input Scripts .......................................................................................................................... 5

General Variable Naming Convention.................................................................. 6 GuiXT Development Scripts Listing .................................................................... 7

GuiXT Scripts ....................................................................................................................... 7 MENUS000.E0040.TXT .......................................................................................................................... 7 SAPLSMTR_NAVIGATION.E0100.TXT, SAPLSMTR_NAVIGATION.E0101.TXT........................ 7 SAPML03T.E0102.TXT .......................................................................................................................... 7 SAPML03T.E0105.TXT .......................................................................................................................... 7 SAPML03T.E0106.TXT .......................................................................................................................... 7 LB12_MOBILE.TXT ............................................................................................................................... 7 LB12_DESKTOP.TXT............................................................................................................................. 7 SAPML03T.E0132.TXT .......................................................................................................................... 8 LB12_PROCESSED_MOBILE.TXT....................................................................................................... 8 LB12_PROCESSED_DESKTOP.TXT.................................................................................................... 8 SAPMM07M.E0400.TXT ........................................................................................................................ 8 DELMENU.TXT ...................................................................................................................................... 8 MB1B_MOBILE.TXT ............................................................................................................................. 8 MB1B_DESKTOP.TXT........................................................................................................................... 8 SAPLSPO1.E0100.TXT ........................................................................................................................... 9

Input Scripts ........................................................................................................................ 10 MB1B_SCROLL.TXT ........................................................................................................................... 10 MB1B_CLEAR.TXT.............................................................................................................................. 10 DONOTHING.TXT................................................................................................................................ 10 MB1B_SAVE.TXT ................................................................................................................................ 10 MB1B_UPDATE_TABLE.TXT ............................................................................................................ 10 LB12_GET_PROCESSEDVALUES.TXT ............................................................................................ 11 LB12_GETFIELDATT.TXT.................................................................................................................. 11 LB12_NEXTITM.TXT .......................................................................................................................... 11 LB12_POPUP.TXT ................................................................................................................................ 11 LB12_GET_TABLEVALUES.TXT ...................................................................................................... 11 LB12_SAVE.TXT .................................................................................................................................. 12 LB12_SCROLL.TXT ............................................................................................................................. 12 LB12_STOCKLIST.TXT....................................................................................................................... 12 NEXT_SCRN.TXT................................................................................................................................. 12 LB12_GENTOSCRN.TXT .................................................................................................................... 12

Scripts Process Flow........................................................................................... 13 GuiXT Modified Screen: MB1B enter transfer posting – initial screen............................. 13

Page 3: GuiXT Solution WM-0002 - Liquid UI - Home GuiXT Solution WM-0002 Page 1 of 21 ... In this case all variables that contain “z_mb1b” prefix get reset ... Script reads plant and storage

GuiXT Solution WM-0002

Page 3 of 21

SAPMM07M.E0400.TXT ...................................................................................................................... 13 Input Scripts ........................................................................................................................ 14

MB1B_SAVE.TXT ................................................................................................................................ 14 GuiXT Modified Screen: LT04 Create Transfer Order – Desktop Layout ........................ 16

SAPML03T.E0106.TXT ........................................................................................................................ 16 Input Scripts ........................................................................................................................ 17

LB12_NEXTITM.TXT .......................................................................................................................... 17 LB12_SAVE.TXT .................................................................................................................................. 19

Page 4: GuiXT Solution WM-0002 - Liquid UI - Home GuiXT Solution WM-0002 Page 1 of 21 ... In this case all variables that contain “z_mb1b” prefix get reset ... Script reads plant and storage

GuiXT Solution WM-0002

Page 4 of 21

GuiXT Development Business Rules Below are the rules taken into consideration for GuiXT Customized screens.

1. The value of below GuiXT variable is checked for GuiXT screen display. V[MODE]

Page 5: GuiXT Solution WM-0002 - Liquid UI - Home GuiXT Solution WM-0002 Page 1 of 21 ... In this case all variables that contain “z_mb1b” prefix get reset ... Script reads plant and storage

GuiXT Solution WM-0002

Page 5 of 21

General Script Naming Convention GuiXT Scripts Purpose: For Screen Interface. Dictates how the screen appears to the user GuiXT Script Names cannot be altered. It is a must to keep the same name as the system suggested. This is how GuiXT scripts are linked to SAP Screen. Typical GuiXT Script Name: SAPML03T.E0106.TXT SAPML03T ABAP Program Name E 1 Character Language Key

0106 Screen Number .TXT File Extension (Text Files)

Input Scripts Purpose: Facilitates synchronization of data with SAP Screens. Facilitates multiple screen navigation and screen level data validation Input scripts can be assigned any name. Following naming convention is followed for Input Scripts TCODE_PURPOSE.TXT (Example: MB1B_SAVE.TXT) TCODE Transaction Code for which the script refers to (Example: MB1B, TRANSFER POSTING) PURPOSE Action that is performed by the input script (Example: SAVE for creating transfer posting)

Page 6: GuiXT Solution WM-0002 - Liquid UI - Home GuiXT Solution WM-0002 Page 1 of 21 ... In this case all variables that contain “z_mb1b” prefix get reset ... Script reads plant and storage

GuiXT Solution WM-0002

Page 6 of 21

General Variable Naming Convention For all variables following naming convention is used Note: Variable Names are CASE SENSITIVE z_tcode_field z Used as variable prefix tcode Lower Case Transaction Code for which the variable refers to (Example: mm01 for create material) field Lower Case field name referring to SAP field (Example: bum for Base Unit of Measure) z_lb12_proc_mat&V[idx] Variable is used to store the material number that is put in

transfer order. V[idx] is used to index the materials that are entered in transfer posting.

Page 7: GuiXT Solution WM-0002 - Liquid UI - Home GuiXT Solution WM-0002 Page 1 of 21 ... In this case all variables that contain “z_mb1b” prefix get reset ... Script reads plant and storage

GuiXT Solution WM-0002

Page 7 of 21

GuiXT Development Scripts Listing GuiXT Scripts MENUS000.E0040.TXT Purpose: Initial screen after login to SAP. Script executes a function code “/nsmen” only if the view is GuiXT to navigate to session manager transaction where the GuiXT modifications are. The view is checked by global variable V[MODE]. SAPLSMTR_NAVIGATION.E0100.TXT, SAPLSMTR_NAVIGATION.E0101.TXT Purpose: Session manager main menu screen on which the first GuiXT interface is designed on. The screen contains a pushbutton which takes user to MB1B to enter transfer posting. There are two screens that could be displayed on session manager transaction. Both screens are taken into account to display same view to the user. SAPML03T.E0102.TXT Purpose: LT04 pop up screen. Script executes a process to skip the pop up screen that appears during navigation to create transfer order. SAPML03T.E0105.TXT Purpose: LT04 Create Transfer Order overview screen. Depending on the GuiXT view (if not V[MODE=SAP]), script forces the process to navigate to stock list (Enter "/7") where users can pick quantities. SAPML03T.E0106.TXT Purpose: LT04 Create Transfer Order from transfer requirement quantity selection screen. This is where users can pick the quantities from different storage bins. Script contains modifications such as deletion and position of native sap screen elements and it includes the layouts for mobile and desktop environment. LB12_MOBILE.TXT Purpose: LT04 Stock List quantity selection include screen for mobile environment. Script includes custom table for mobile device layout which stores the selection quantity, type, storage bin and available stock values. This script displays the mobile layout for user to select the quantities from different storage bins. LB12_DESKTOP.TXT Purpose: LT04 Stock List quantity selection include screen for desktop environment. Script includes modifications on the native SAP stock table such as resizing of columns or change of column headers.

Page 8: GuiXT Solution WM-0002 - Liquid UI - Home GuiXT Solution WM-0002 Page 1 of 21 ... In this case all variables that contain “z_mb1b” prefix get reset ... Script reads plant and storage

GuiXT Solution WM-0002

Page 8 of 21

SAPML03T.E0132.TXT Purpose: LT04 Processed Items screen. Script includes layouts created both for mobile and desktop. A custom table is created for mobile using GuiXT fields. The user can click on “stock list” pushbutton on the screen to change the quantities of line items. LB12_PROCESSED_MOBILE.TXT Purpose: LT04 Stock List overview include screen for mobile environment. Script includes custom table for mobile device layout which stores the material, transfer quantity, unit and an indicator whether the material is added to transfer order or not. This script creates the screen where user can view which materials are processed and put in transfer order. LB12_PROCESSED_DESKTOP.TXT Purpose: LT04 Stock List overview include screen for desktop environment. Script includes modifications on the native SAP stock table such as resizing of columns or change of column headers. This script creates the screen where user displays the overview for the materials that are processed and put in transfer order. SAPMM07M.E0400.TXT Purpose: MB1B Enter transfer posting initial screen on which the first GuiXT interface is designed on. When user is on this screen for the first time, it checks the version of SAPGUI to differentiate between mobile and desktop platforms. A global variable ‘platform’ (V[platform]) is ten set according to this differentiation. DELMENU.TXT Purpose: Include script for deleting menu items. It is included by; SAPLSMTR_NAVIGATION.E0100.TXT, SAPLSMTR_NAVIGATION.E0101.TXT, SAPML03T.E0106.TXT, SAPML03T.E0132.TXT, SAPMM07M.E0400.TXT It deletes the back, cancel, save, exit buttons from the screen and creates a loop to find out how many menu items exist on the screen and deletes all of them. MB1B_MOBILE.TXT Purpose: Include script for creating the mobile layout for mb1b screen. It is included by; SAPMM07M.E0400.TXT It deletes unwanted native SAP screen elements, repositions the used ones and creates a custom table for user to enter the material and quantity along with the pushbuttons to scroll in the table. MB1B_DESKTOP.TXT Purpose: Include script for creating the dektop layout for mb1b screen. It is included by; SAPMM07M.E0400.TXT It deletes unwanted native SAP screen elements, repositions the used ones and creates a custom table for user to enter the material and quantity along with the pushbuttons to scroll in the table. The only difference between mobile and desktop layout is that the number of columns in the custom table is less in mobile

Page 9: GuiXT Solution WM-0002 - Liquid UI - Home GuiXT Solution WM-0002 Page 1 of 21 ... In this case all variables that contain “z_mb1b” prefix get reset ... Script reads plant and storage

GuiXT Solution WM-0002

Page 9 of 21

layout because of the space that has to be utilized in the mobile device. While plant and storage location are created as readonly fields in custom table in desktop layout, they do not exist as columns in mobile layout. SAPLSPO1.E0100.TXT Purpose: LT04 insufficient quantity pop up screen. Screen is displayed to the user if the total quantity entered in LT04 (selection quantity) is less than the quantity entered in MB1B transaction. Different actions are taken based on different selections on this pop up screen.

Page 10: GuiXT Solution WM-0002 - Liquid UI - Home GuiXT Solution WM-0002 Page 1 of 21 ... In this case all variables that contain “z_mb1b” prefix get reset ... Script reads plant and storage

GuiXT Solution WM-0002

Page 10 of 21

Input Scripts MB1B_SCROLL.TXT Purpose: It scrolls through the custom table that is created in mobile and desktop layout for mb1b - enter transfer posting screen. It scrolls per page at a time. Invoked From: MB1B_MOBILE.TXT, MB1B_DESKTOP.TXT MB1B_CLEAR.TXT Purpose: Script resets all the global GuiXT variables for different variable sets. It uses wildcard variables to reset all variables at one time such as; Set V[z_mb1b*] "" In this case all variables that contain “z_mb1b” prefix get reset At the end script returns user to the initial screen of current transaction. Invoked From: MB1B_DESKTOP.TXT, MB1B_MOBILE.TXT, SAPML03T.E0106.TXT, SAPML03T.E0132.TXT DONOTHING.TXT Purpose: Returns the user to the initial screen of the transaction. To create custom table, pushbuttons are created as header of the table but in order to disable the click on a pushbutton, this script gets created that simply does only return on the click, which makes user to stay on the same screen. Invoked From: LB12_MOBILE.TXT, LB12_PROCESSED_MOBILE.TXT, MB1B_DESKTOP.TXT, MB1B_MOBILE.TXT MB1B_SAVE.TXT Purpose: Script saves the user entries for material and quantity in MB1B - enter transfer posting - transaction after checking the required entries. After saving transfer posting, script gets the material document number from the save message and navigates to LB12 transaction to process material document and create the transfer order within LB12. Invoked From: MB1B_DESKTOP.TXT, MB1B_MOBILE.TXT MB1B_UPDATE_TABLE.TXT Purpose: Script reads plant and storage location data from the items table in MB1B and put them in the custom table for desktop layout. Plant and storage locations are created as columns in the custom table for desktop layout and they are readonly. Invoked From: MB1B_DESKTOP.TXT

Page 11: GuiXT Solution WM-0002 - Liquid UI - Home GuiXT Solution WM-0002 Page 1 of 21 ... In this case all variables that contain “z_mb1b” prefix get reset ... Script reads plant and storage

GuiXT Solution WM-0002

Page 11 of 21

LB12_GET_PROCESSEDVALUES.TXT Purpose: Script gets executed if platform is mobile and there is no value in V[z_lb12_showprocessed] GuiXT global variable. Script scrolls in the material table and gets the material no, transfer order quantity, unit of measure and TO order created indicator data into GuiXT fields. It displays these data on the processed items custom table in mobile platform. Invoked From: SAPML03T.E0132.TXT LB12_GETFIELDATT.TXT Purpose: Script gets field attributes of two pushbuttons. The pushbuttons are “Active” and “Inactive” pushbuttons. If they are both deactivated, then user is on the processed items tab. Invoked From: SAPML03T.E0132.TXT LB12_NEXTITM.TXT Purpose: Script scrolls through the custom table and sets the selected quantity from the custom table to the selected quantity column in the native sap table for each material. It gets the open quantity that can be put in order and returns an error to the user based on the comparison between total qty and open quantity. Invoked From: LB12_MOBILE.TXT LB12_POPUP.TXT Purpose: Script gets executed on the pop up screen that appears when the entered quantity is less than the original quantity. User is given “YES”, “No” and “CANCEL” options on the pop up. Script runs on “NO” and “CANCEL” which removes the pop up and takes user to the stock list screen. After navigating to stock list screen, it executes an include file which gets the values from native screen to GuiXT variables to display in custom table created for selecting quantities from storage bins. Invoked From: SAPLSPO1.E0100.TXT LB12_GET_TABLEVALUES.TXT Purpose: Script performs a table scroll on quantity selection screen to get the selected quantity, type, storage bins and available stock data for the current material. Script gets executed either on the pop up that appears in case the entered quantity is greater than the total quantity while navigating to next item or on mobile layout. For the script to be executed in mobile layout value of V[z_lb12_readval] GuiXT variable is checked. Once script gets executed, in order to prevent process going into continuous loop, this variable is reset. For each material, on the navigation script (lb12_nextitm.txt) the value of the V[z_lb12_readval] flag is set to “X” again. Invoked From: LB12_POPUP.TXT, LB12_MOBILE.TXT

Page 12: GuiXT Solution WM-0002 - Liquid UI - Home GuiXT Solution WM-0002 Page 1 of 21 ... In this case all variables that contain “z_mb1b” prefix get reset ... Script reads plant and storage

GuiXT Solution WM-0002

Page 12 of 21

LB12_SAVE.TXT Purpose: Script saves the transfer order with the quantities user has selected from the storage bins and confirms the transfer order internally. If there is any error happens during save or confirm order, script displays the error to the user. Invoked From: SAPML03T.E0132.TXT LB12_SCROLL.TXT Purpose: Script scrolls through the custom table created for quantity selection from storage bins. It uses a parameter (l_val) to determine the action (up or down) that is initiated by the user by clicking on the navigation buttons. Invoked From: LB12_MOBILE.TXT, LB12_PROCESSED_MOBILE.TXT LB12_STOCKLIST.TXT Purpose: Script takes user to the stock list for them to select from available quantity for the materials from storage bins again. If quantity put on order reached to the total quantity created on transfer posting, then script returns a message to the user. Invoked From: SAPML03T.E0132.TXT NEXT_SCRN.TXT Purpose: Script toggles between native SAP and GuiXT screens by assigning a parameter (l_val) value that is defined on click of the toggle pushbutton on toolbar to a global GuiXT variable (V[MODE]) and by checking the value of V[MODE] in GuiXT scripts listed below to determine which view to display to the user. Invoked From: SAPLSMTR_NAVIGATION.E0100.TXT, SAPLSMTR_NAVIGATION.E0101.TXT LB12_GENTOSCRN.TXT Purpose: Script skips the pop up screens that appear during navigating to create transfer order out of transfer requirement that is created. Invoked From: SAPML03T.E0102.TXT

Page 13: GuiXT Solution WM-0002 - Liquid UI - Home GuiXT Solution WM-0002 Page 1 of 21 ... In this case all variables that contain “z_mb1b” prefix get reset ... Script reads plant and storage

GuiXT Solution WM-0002

Scripts Process Flow GuiXT Modified Screen: MB1B enter transfer posting – initial screen SAPMM07M.E0400.TXT Interface is displayed when user hits “Transfer Posting” button in SAP easy access menu

Page 13 of 21

Page 14: GuiXT Solution WM-0002 - Liquid UI - Home GuiXT Solution WM-0002 Page 1 of 21 ... In this case all variables that contain “z_mb1b” prefix get reset ... Script reads plant and storage

GuiXT Solution WM-0002

Page 14 of 21

Input Scripts MB1B_SAVE.TXT Invoked From: SAPMM07M.E0400.TXT Transaction Code: MB1B – Create Transfer Posting When Executed: Clicking the ‘Save’ button on the toolbar. Script Logic: It checks all of the required fields one by one if they have values. It saves the user entries to SAP fields and handles errors during the save process. After capturing, successfully saved message, it navigates user to LB12 transaction to process material document and within that transaction it executes a process to create transfer order in foreground (LT04). It finally takes user to stock list screen to select the quantities from storage bins. Step 1 Script gets the material slip and document header text to GuiXT variables to be used in save process in creating transfer order. If there is an error during create transfer order process, these values are set to SAP fields again to pass the error. Script checks the required fields and if they do not have any data, it returns an error to the user. if V[z_mb1b_mat&V[ii]] and not V[z_mb1b_qty&V[ii]] //if there is mat and no quantity Return "E: Enter a quantity for row &V[ii]" "-statusline" else if V[z_mb1b_qty&V[ii]] and not V[z_mb1b_mat&V[ii]] //if there is quantity and no mat Return "E: Enter a material for row &V[ii]" "-statusline" endif endif If there is a system error that is given such as complaining about the material or quantity data, script stores the system error to the GuiXT variable and displays the error to the user. if V[_lasterror] Set V[z_mb1b_error] "&V[_lasterror]" //capture last error Set V[_lasterror] "" //reset last error variable Return "&V[z_mb1b_error]" "-statusline" //display error on statusline endif Step 2 If there is no error, script navigates to enter receiving storage location along with materials and quantities t At user enters on the custom table. GuiXT indexes (V[xx] and V[yy]) are created which store the index for native SAP screen elements and GuiXT screen elements for material and quantity respectively.

Page 15: GuiXT Solution WM-0002 - Liquid UI - Home GuiXT Solution WM-0002 Page 1 of 21 ... In this case all variables that contain “z_mb1b” prefix get reset ... Script reads plant and storage

GuiXT Solution WM-0002

Page 15 of 21

Set F[Material(&V[xx])] "&V[z_mb1b_mat&V[yy]]" //set material column Set F[Quantity(&V[xx])] "&V[z_mb1b_qty&V[yy]]" //set quantity column Step 3 Script executes enter to save the values. During this process, if an error happens; script captures the error to V[z_mb1b_error] GuiXT error variable, navigates user back to initial screen of MB1B and displays the error message to the user. Otherwise it captures successful save message and extracts the material document from the successful message to the V[z_mb1b_doc_no] GuiXT variable to be used in LB12 transaction. It stores the successful message on save to V[z_mb1b_mes] variable to display it to the user on stock list screen. (LT04) Step 4 Script navigates to LB12. Enter "/nlb12" It sets the material document number captured from the successful message to SAP field. Set F[Material Document] "&V[z_mb1b_doc_no]" It goes into the transaction and within the transaction it executes “/44” to create transfer order in foreground. Step 5 Script executes “/7” to navigate stock list for single items and then it executes “/18” to navigate to stock list for multiple items.

Page 16: GuiXT Solution WM-0002 - Liquid UI - Home GuiXT Solution WM-0002 Page 1 of 21 ... In this case all variables that contain “z_mb1b” prefix get reset ... Script reads plant and storage

GuiXT Solution WM-0002 GuiXT Modified Screen: LT04 Create Transfer Order – Desktop Layout SAPML03T.E0106.TXT Interface is displayed when user hits “Save” button in MB1B

Page 16 of 21

Page 17: GuiXT Solution WM-0002 - Liquid UI - Home GuiXT Solution WM-0002 Page 1 of 21 ... In this case all variables that contain “z_mb1b” prefix get reset ... Script reads plant and storage

GuiXT Solution WM-0002

Page 17 of 21

Input Scripts LB12_NEXTITM.TXT Invoked From: SAPML03T.E0106.TXT Transaction Code: LT04 – Create Transfer Order from Transfer Requirement When Executed: Clicking the ‘Next Item’ button on the toolbar. Script Logic: Script gets executed only on mobile layout since the custom table in mobile layout is created with GuiXT fields. Desktop and mobile platforms have different screen resolutions therefore while standard SAP table is used for desktop view; a custom table is created for mobile platform. Considering this, standard functionality that runs on native “Next item” button has been overwritten with a custom functionality in mobile platform with this script to get the values entered in custom fields. Script scrolls through the custom table to write the user entries for selection quantity to the native SAP table. Step 1 It gets the table attributes of the SAP table to determine the first visible row and last visible row on the screen as well a last row where the last data exists. When the execution starts, if first row in the native table is not visible, script scrolls to the first row. if V[FVisRow=1] goto new_row endif // scroll to first line Enter "/ScrollToLine=1" Table="T[Table]" Step 2 To scroll to the first row, script performs an action which requires the declaration of a screen statement. To navigate to the correct screen, script uses goto-label structure and declares the screen statement. Every time a new screen is reached in a table control, new attributes must be retrieved from the table to calculate the new first and last visible rows of the table on the current screen. label new_screen Screen SAPML03T.0106 GetTableAttribute T[Table] FirstVisibleRow=FVisRow LastVisibleRow=LVisRow LastRow=LastRow

Page 18: GuiXT Solution WM-0002 - Liquid UI - Home GuiXT Solution WM-0002 Page 1 of 21 ... In this case all variables that contain “z_mb1b” prefix get reset ... Script reads plant and storage

GuiXT Solution WM-0002

Page 18 of 21

Step 3 While navigating through the records in the table for the current screen, script determines whether there is any more data to read in table by checking if last row is reached on the screen. If not, it stops executing the scroll. if V[absrow>&V[LastRow]] goto end_of_table endif it also checks whether last visible row is reached in the table to determine whether it has to scroll to a new page to see if there are more data to read or not. if V[absrow>&V[LVisRow]] Enter "/ScrollToLine=&V[absrow]" Table="T[Table]" goto new_screen endif In this logic, script performs an action which requires a declaration of a screen statement. Before the declaration happens script takes user to the point where declaration needs to happen and continues the logic from that point. Step 4 After checking the scroll status, script checks if there are any storage bins data for the current row. If it can not find any, it stops scrolling because that means there is no more data to read in the table. Script checks this condition to execute scroll faster. Step 5 If storage data exists for the current row, it updates the selected quantity column of the current row with the user entry and calculates the total quantity in transfer order. It increments the scroll indexes and continues to scroll. Set cell[Table,Selected quantity,&V[relrow]] "&V[z_lb12_selqty&V[relrow]]" Set V[z_lb12_totalqty] "&V[z_lb12_totalqty]" + "&V[z_lb12_selqty&V[relrow]]" Set V[absrow] &V[absrow] + 1 Set V[relrow] &V[relrow] + 1 Step 6 Script gets the open quantity and if total quantity that has been calculated is greater than the open quantity, it returns an error to the user and clears out the selected quantity for all storage bins for that material. if V[z_lb12_totalqty>&V[z_lb12_oqty]] Set V[z_lb12_error] "E: Scheduled quantity greater than quantity to be removed." Set V[xx] "1"

Page 19: GuiXT Solution WM-0002 - Liquid UI - Home GuiXT Solution WM-0002 Page 1 of 21 ... In this case all variables that contain “z_mb1b” prefix get reset ... Script reads plant and storage

GuiXT Solution WM-0002

Page 19 of 21

Label clear_next_qty if V[xx>&V[LastRow]] goto done_clear endif Set cell[Table,Selected quantity,&V[xx]] "" Set V[xx] "&V[xx]" + "1" goto clear_next_qty Label done_clear goto show_error endif The error is shown to the user at the end if V[z_lb12_error] Message "&V[z_lb12_error]" "-statusline" Set V[z_lb12_error] "" endif If there is no error, it scrolls back to first row of the table and executes “/16” LB12_SAVE.TXT Invoked From: SAPML03T.E0106.TXT Transaction Code: LT04 – Create Transfer Order from Transfer Requirement When Executed: Clicking the ‘Save’ button on the toolbar. “Save” button will appear on the toolbar after all items are navigated to select quantities and there are no more items to navigate. Script Logic: Script saves the transfer order with the selected quantities, handles any error that happen during save and displays errors to the user on the same screen. Otherwise it takes the user to LT12 transaction to confirm the transfer order internally. It captures the error if transfer order number is wrong. After posting the confirmed order, it takes user back to MB1B transaction. It displays confirmation errors on MB1B transaction Step 1 Script sets two error variables V[z_lt12_error] – To store confirmation errors V[z_lb12_error] – To store errors during save.

Page 20: GuiXT Solution WM-0002 - Liquid UI - Home GuiXT Solution WM-0002 Page 1 of 21 ... In this case all variables that contain “z_mb1b” prefix get reset ... Script reads plant and storage

GuiXT Solution WM-0002

Page 20 of 21

It executes “/11” to save user entries that were populated in sap table in lb12_nextitm inputscript. During this process if any error happens, it captures the system error and returns the error to the user on the same screen. if V[_lasterror] Set V[z_lb12_error] "&V[_lasterror]" Set V[_lasterror] "" return "&V[z_lb12_error]" "-statusline" endif Step 2 If save is successful, script captures the order number from successful message and navigates to confirm transfer order (LT12) transaction. It puts the order number in sap field and navigates into the transaction. Set V[z_lb12_message] "&V[_message]" Set V[z_lb12_tord_num] "&V[_message]" search="order" Enter "/nlt12" // Confirm Transfer Order: Initial Screen Screen SAPML03T.0111 Retry on Error Set F[Transfer order no.] "&V[z_lb12_tord_num]" Enter "%_GS 0 1" Script might execute above logic multiple times dues to the locking status of the order. Sometimes SAP locks the order until it finishes the previous execution on it, therefore script tries to get into the confirmation for the order created couple times using “Retry on Error” command. Step 3 If the order number is wrong, script captures the system error, stores it in the corresponding variable and displays it on MB1B transaction to the user. It determines the navigation schema by using goto-label structure. Error is displayed at the very end of the script. if V[_lasterror] Set V[z_lt12_error] "&V[_lasterror]" Set V[_lasterror] "" goto show_lt12_error endif ------- Label show_lt12_error Enter "/nmb1b"

Page 21: GuiXT Solution WM-0002 - Liquid UI - Home GuiXT Solution WM-0002 Page 1 of 21 ... In this case all variables that contain “z_mb1b” prefix get reset ... Script reads plant and storage

GuiXT Solution WM-0002

Page 21 of 21

Step 4 If there is no error, it confirms the order internally (“/5”) and posts the order.(“/11”). It clears out the variables and navigates user to MB1B transaction.