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

Program Report

Former Member
0 Likes
799

Hi all,

I'm needing a help at next program report:

SELECTION-SCREEN: BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.

PARAMETERS: p_arq1 LIKE rlgrap-filename,

p_arq2 LIKE rlgrap-filename,

p_arq3 LIKE rlgrap-filename.

SELECTION-SCREEN: END OF BLOCK b1.

SELECTION-SCREEN PUSHBUTTON 1(20) text-100

USER-COMMAND carga.

AT SELECTION-SCREEN.

IF sscrfields-ucomm = 'CARGA'.

WRITE: 'teste'.

ENDIF.

I need to write "Teste" at Report, but it's nothing doing this.

I try with Leave to List-Processing...

it's show what I write, but it's not return to First Screen again, anyone can help me please??

Regards

Allan Cristian

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
783

Hi,

The mistake you are doing is that, you are having the WRITE statement in AT SELECTION SCREEN.

Have the WRITE statement in the START-OF-SELECTION event.

REward if helpful

Regards.

8 REPLIES 8
Read only

Former Member
0 Likes
783

hi use the usercommand in the capital letters..

regards,

venkat.

Read only

Former Member
0 Likes
783

Hi,

Try giving this code in AT SELECTION-SCREEN OUTPUT and check and give user command in caps.

Reward if helpful.

Regards,

Ramya

Read only

Former Member
0 Likes
783

This code is working, however the Report is not shown because you are writing to the report that immediatly gets covered with the screen. In this code, I show it is working by putting 'Teste" back in to p_arq1.


SELECTION-SCREEN: BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.
PARAMETERS: p_arq1 LIKE rlgrap-filename,
p_arq2 LIKE rlgrap-filename,
p_arq3 LIKE rlgrap-filename.
SELECTION-SCREEN: END OF BLOCK b1.

SELECTION-SCREEN PUSHBUTTON 1(20) text-100
USER-COMMAND carga.

AT SELECTION-SCREEN.
  CASE sy-ucomm.
    WHEN 'CARGA'.
      WRITE: 'teste'.
      p_arq1 = 'Teste'.   " Line to prove it is working
  ENDCASE.

Edited by: Paul Chapman on Mar 14, 2008 2:27 PM

Read only

Former Member
0 Likes
784

Hi,

The mistake you are doing is that, you are having the WRITE statement in AT SELECTION SCREEN.

Have the WRITE statement in the START-OF-SELECTION event.

REward if helpful

Regards.

Read only

0 Likes
783

hi,

understand, but I need to execute the program when the user press the button "CARGA"(at selection-screen), How can I execute START-OF-SELECTION when press the button?

Regards

Allan Cristian

Read only

Former Member
0 Likes
783

Hi,

In that case, you cannot WRITE it... but may be.. you can display it as an information box.

Reward if helpful.

Regards.

Read only

rodrigo_paisante3
Active Contributor
0 Likes
783

Hi my friend! how are you?

Is it about the program I wrote?

You need to show a text when the user press CARGA button, like "Executado"?

Did you solve this problem? If no, let me know, send me an email and I will help you.

Regards,

RP

Read only

Former Member
0 Likes
783

hi,

in report programming we are not able to execute a program by pressing a push button.even if you press push button also you need to press F8 to execute.

but if your requirement is to show a report output when push button is pressed then it is possible only with modulepool programming.

please reward points if useful.