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

regarding selection screen

Former Member
0 Likes
734

hi,

i am makin report of sales order in which i am using date field by taking select single statement like this : -

SELECT SINGLE EDATU FROM VBEP INTO <b>SCH_DATE</b> WHERE VBELN = ITSO-VBELN AND POSNR = ITSO-POSNR.

<b>write : sch_date</b>.

I want to use selection screen of it when i run report ,i know d method of making selection screen but to make selection screen of variable defined for filed like dis is bit confusing for me .

Plz reply as fast as possible as it is urgent for me,help given will be definately rewarded.

1 ACCEPTED SOLUTION
Read only

former_member188827
Active Contributor
0 Likes
705

parameters zvbeln type vbep-vbeln.

parameters:zposnr type vbep-posnr.

move zvbeln to itso-vbeln.

move zposnr to itso-posnr.

SELECT SINGLE EDATU FROM VBEP INTO SCH_DATE WHERE VBELN = ITSO-VBELN AND POSNR = ITSO-POSNR.

write : sch_date.

plz reward points if dis helps

6 REPLIES 6
Read only

former_member188827
Active Contributor
0 Likes
705

parameters zvbeln type vbep-vbeln.

parameters zposnr type vbep-posnr.

move zvbeln to itso-vbeln.

move zposnr to itso-posnr.

den carrout ur selection.

plz reward points if dis helps

Message was edited by:

abapuser

Read only

Former Member
0 Likes
705

can you plz explain your requirement in detail?

what exactly you want to display in selection screen?

Read only

0 Likes
705

i want to display selection screen like dis : -

SALES ORDER SCHEDULE DATE _______ TO __________

I had declared dis field in my report by using select single statement and d code of dis statement as follows: -

SELECT SINGLE EDATU FROM VBEP INTO <b>SCH_DATE</b> WHERE VBELN = ITSO-VBELN AND POSNR = ITSO-POSNR.

write: / SCH_DATE.

I want to make d selection screen of dis field which is written in d write statement above...

plzz reply fast and get rewarded.

Read only

0 Likes
705

call ur own screen after select stament and display data on it.u cant do dis on standard selection screen.

call screen 100.

provide SALES ORDER SCHEDULE DATE an to as label and create an output field on screen say zout which 'll hold dis value.

use da following statement in PBO of screen 100.

zout = sch_date.

Read only

former_member188827
Active Contributor
0 Likes
706

parameters zvbeln type vbep-vbeln.

parameters:zposnr type vbep-posnr.

move zvbeln to itso-vbeln.

move zposnr to itso-posnr.

SELECT SINGLE EDATU FROM VBEP INTO SCH_DATE WHERE VBELN = ITSO-VBELN AND POSNR = ITSO-POSNR.

write : sch_date.

plz reward points if dis helps

Read only

Former Member
0 Likes
705

Hi Ric,

I think ITSO is an internal table which you are filling some where in your program.

Use the below code instead of writing select single...

TABLES: vbep.

SELECT-OPTIONS: s_vbeln FOR vbep-vbeln,

s_posnr FOR vbep-posnr.

DATA: BEGIN OF it_vbep OCCURS 0,

vbeln LIKE vbep-vbeln,

posnr LIKE vbep-posnr,

edatu LIKE vbep-edatu,

END OF it_vbep.

DATA: sch_date LIKE vbep-edatu.

SELECT vbeln posnr edatu FROM vbep

INTO TABLE it_vbep

WHERE vbeln IN s_vbeln

AND posnr IN s_posnr.

IF sy-subrc = 0.

SORT it_vbep BY vbeln posnr.

ENDIF.

READ TABLE it_vbep WITH KEY vbeln = itso-vbeln

posnr = itso-posnr.

IF sy-subrc = 0.

sch_date = it_vbep-edatu.

ENDIF.

write:/ sch_date.