Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

SEARCH HELP FM error

vallamuthu_madheswaran2
Active Contributor
0 Likes
473

Hi friends,

I am using the function module 'F4IF_INT_TABLE_VALUE_REQUEST' for help request. when i press f4 in the parameter field i got the pop-up screen but the values are not diaplayed. in the bottom of the pop-screen it displayed the following message "6 records found". the coding is given below.

DATA: BEGIN OF I_BRCH OCCURS 0,

BR_CODE(3) TYPE C,

BR_DESC(15) TYPE C,

END OF I_BRCH.

PARAMETERS: P_BRANCH(3) TYPE C.

AT SELECTION-SCREEN ON VALUE-REQUEST FOR P_BRANCH .

PERFORM BRCH_CODE.

CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'

EXPORTING

RETFIELD = 'BR_CODE'

DYNPPROG = SY-REPID

DYNPNR = '1000'

DYNPROFIELD = 'P_BRANCH'

VALUE_ORG = 'S'

TABLES

VALUE_TAB = I_BRCH

EXCEPTIONS

PARAMETER_ERROR = 1

NO_VALUES_FOUND = 2

OTHERS = 3.

IF SY-SUBRC <> 0.

MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO

WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.

ENDIF.

&----


*& Form BRCH_CODE

&----


FORM BRCH_CODE .

I_BRCH-BR_CODE = 311.

I_BRCH-BR_DESC = 'Calcutta'.

append i_brch.

I_BRCH-BR_CODE = 313.

I_BRCH-BR_DESC = 'Chennai'.

append i_brch.

I_BRCH-BR_CODE = 317.

I_BRCH-BR_DESC = 'Hyderabad'.

append i_brch.

I_BRCH-BR_CODE = 310.

I_BRCH-BR_DESC = 'Mubmai'.

append i_brch.

I_BRCH-BR_CODE = 312.

I_BRCH-BR_DESC = 'New Delhi'.

append i_brch.

I_BRCH-BR_CODE = 314.

I_BRCH-BR_DESC = 'Pune'.

append i_brch.

ENDFORM. " BRCH_CODE

thanks & Regards,

vallamuthu.M

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
454

Hi vallamuthu,

1. minor mistake

2. while declaring the internal table,

use LIKE (for the fields),

and not type.

3.

eg.

<b>BR_CODE LIKE T001-LAND1,

BR_DESC LIKE T001-LAND1,</b>

4. Then it will work fine. I just checked it.

regards,

amit m.

Hi friends,

I am using the function module 'F4IF_INT_TABLE_VALUE_REQUEST' for help request. when i press f4 in the parameter field i got the pop-up screen but the values are not diaplayed. in the bottom of the pop-screen it displayed the following message "6 records found". the coding is given below.

DATA: BEGIN OF I_BRCH OCCURS 0,

BR_CODE(3) TYPE C,

BR_DESC(15) TYPE C,

END OF I_BRCH.

PARAMETERS: P_BRANCH(3) TYPE C.

AT SELECTION-SCREEN ON VALUE-REQUEST FOR P_BRANCH .

PERFORM BRCH_CODE.

CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'

EXPORTING

RETFIELD = 'BR_CODE'

DYNPPROG = SY-REPID

DYNPNR = '1000'

DYNPROFIELD = 'P_BRANCH'

VALUE_ORG = 'S'

TABLES

VALUE_TAB = I_BRCH

EXCEPTIONS

PARAMETER_ERROR = 1

NO_VALUES_FOUND = 2

OTHERS = 3.

IF SY-SUBRC <> 0.

MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO

WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.

ENDIF.

&----


*& Form BRCH_CODE

&----


FORM BRCH_CODE .

I_BRCH-BR_CODE = 311.

I_BRCH-BR_DESC = 'Calcutta'.

append i_brch.

I_BRCH-BR_CODE = 313.

I_BRCH-BR_DESC = 'Chennai'.

append i_brch.

I_BRCH-BR_CODE = 317.

I_BRCH-BR_DESC = 'Hyderabad'.

append i_brch.

I_BRCH-BR_CODE = 310.

I_BRCH-BR_DESC = 'Mubmai'.

append i_brch.

I_BRCH-BR_CODE = 312.

I_BRCH-BR_DESC = 'New Delhi'.

append i_brch.

I_BRCH-BR_CODE = 314.

I_BRCH-BR_DESC = 'Pune'.

append i_brch.

ENDFORM. " BRCH_CODE

thanks & Regards,

vallamuthu.M

2 REPLIES 2
Read only

Former Member
0 Likes
455

Hi vallamuthu,

1. minor mistake

2. while declaring the internal table,

use LIKE (for the fields),

and not type.

3.

eg.

<b>BR_CODE LIKE T001-LAND1,

BR_DESC LIKE T001-LAND1,</b>

4. Then it will work fine. I just checked it.

regards,

amit m.

Read only

Former Member
0 Likes
454

Hi.......

Declare like this:

<b>

BR_CODE LIKE T001-LAND1,

BR_DESC LIKE T005T-LANDX,</b>

it will work fine.....

Regards,

Suresh......