Skip to Content
0
Former Member
Sep 17, 2007 at 05:42 AM

Need help AT LINE SELECTION

33 Views

Hi Guys,

I need ur help regarding my coding: AT LINE SELECTION.

Here is my codes, but it is not working. 😔

AT LINE-SELECTION.

IF ( wa_list-auart = 'ZCS' AND wa_list-auart = 'ZSA' ).

IF NOT wa_list-sonum IS INITIAL.

SET PARAMETER ID 'AUN' FIELD wa_list-sonum.

CALL TRANSACTION 'VF01' AND SKIP FIRST SCREEN.

CLEAR wa_list-sonum.

ENDIF.

ELSE.

IF NOT wa_list-drnum IS INITIAL.

SET PARAMETER ID 'AUN' FIELD wa_list-drnum.

CALL TRANSACTION 'VF01' AND SKIP FIRST SCREEN.

CLEAR wa_list-drnum.

ENDIF.

ENDIF.

The requirements are:

1. Data selection on column ‘Item’ + Magnifying Glass Icon click will direct user to transaction code VF01 ====>><b>its working, but the problem is when i click the line item no 1, it wasnt work. Line item no 1 only but the rest items its workin.</b>

2. Sales Order No (VBAK-VBELN) – will be the default value on document column of VF01 if Sales Order Type (VBAK-AUART) = ZCS or ZSA else Delivery No (LIKP-VBELN) will be the default value on document column of VF01. ===><b>the problem is when i click the line item, there is no default Sales Order No or Delivery NO on parameter 'AUN' <Document column> based on if statement.</b>

3. Warning Message ‘Select a line item to proceed.’ will be displayed if no line item selected on magnifying glass icon click. ===> <b>help me on how to codes this one if i click to a non line item, there should be a Warning Message ‘Select a line item to proceed.’</b>

Thanks in advance.

zhien.