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

passing a date

syed_ibrahim5
Active Participant
0 Likes
1,673

hi,

i am getting a date from the selection screen which is a parameter.... i have to pass it to sm13 transaction in the date field....

how could i do it... i cannot use set or get since the target field is a datum field

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,481

Hi,

DATA: bdcdata_wa TYPE bdcdata,

bdcdata_tab TYPE TABLE OF bdcdata.

PARAMETERS : p_date TYPE sy-datum.

DATA : lv_date(10).

WRITE p_date to lv_date.

CLEAR bdcdata_wa.

bdcdata_wa-program = 'SAPMSM13'.

bdcdata_wa-dynpro = '1000'.

bdcdata_wa-dynbegin = 'X'.

APPEND bdcdata_wa TO bdcdata_tab.

CLEAR bdcdata_wa.

bdcdata_wa-fnam = 'BDC_CURSOR'.

bdcdata_wa-fval = 'SAPMSM13-FROM_DATE'.

APPEND bdcdata_wa TO bdcdata_tab.

CLEAR bdcdata_wa.

bdcdata_wa-fnam = 'FROM_DATE'.

bdcdata_wa-fval = lv_date.

APPEND bdcdata_wa TO bdcdata_tab.

call TRANSACTION 'SM13' USING bdcdata_tab .

Edited by: Sumodh P on May 4, 2010 6:08 PM

9 REPLIES 9
Read only

Former Member
0 Likes
1,481

hi ,

try to do it with the help of SUBMIT keyword.

Read only

0 Likes
1,481

hi,

yesterday i asked you about passin the date to sm13.. you suggested me to use submit... could you elobearte...

i used it but i am not getting it... also it should not call the screen sm13 but the next screen that is the executed screen...

taking the date parameter from the selectio screen i have given...

thanks in advance,

syed

Read only

0 Likes
1,481

hi,

yesterday i asked you about passin the date to sm13.. you suggested me to use submit... could you elobearte...

i used it but i am not getting it... also it should not call the screen sm13 but the next screen that is the executed screen...

taking the date parameter from the selectio screen i have given...

thanks in advance,

syed

Read only

Former Member
0 Likes
1,482

Hi,

DATA: bdcdata_wa TYPE bdcdata,

bdcdata_tab TYPE TABLE OF bdcdata.

PARAMETERS : p_date TYPE sy-datum.

DATA : lv_date(10).

WRITE p_date to lv_date.

CLEAR bdcdata_wa.

bdcdata_wa-program = 'SAPMSM13'.

bdcdata_wa-dynpro = '1000'.

bdcdata_wa-dynbegin = 'X'.

APPEND bdcdata_wa TO bdcdata_tab.

CLEAR bdcdata_wa.

bdcdata_wa-fnam = 'BDC_CURSOR'.

bdcdata_wa-fval = 'SAPMSM13-FROM_DATE'.

APPEND bdcdata_wa TO bdcdata_tab.

CLEAR bdcdata_wa.

bdcdata_wa-fnam = 'FROM_DATE'.

bdcdata_wa-fval = lv_date.

APPEND bdcdata_wa TO bdcdata_tab.

call TRANSACTION 'SM13' USING bdcdata_tab .

Edited by: Sumodh P on May 4, 2010 6:08 PM

Read only

0 Likes
1,481

can i use it with submit if so pls elaberate

Read only

Former Member
0 Likes
1,481

Hi,

If you are calling it from report, i think you can write call transaction 'SM13' using BDCDATA.

Populate BDCDATA with that screen field value.

Regards and Best wishes.

Read only

umashankar_sahu
Active Participant
0 Likes
1,481

HI Syed,

Check with FM "DYNP_UPDATE_FIELDS".

Read only

former_member214857
Contributor
0 Likes
1,481

Hi

You can use CALL TRANSACTION statment passing values for the screen fields.

In the ABAP Workbench press F1 to check the correct syntax for this statment.

Regards

Read only

syed_ibrahim5
Active Participant
0 Likes
1,481

the sm13 screen should not be displayed