Application Development 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: 

new Screen as Popup

Former Member
0 Kudos

Hi

I want to have a popup window when clicking &ADD - button where new data has be added (matnr + 3 fields) and then by saving or leaving this screen it should be updated to my t_tab list in alv when the user saves here the Z-database will be updated.

I need the new screen because in my alv list the keyfield matnr mustn't change but the other 3 fields can.

I have my call screen '0100' but when enter or leave/safe the data is lost and I cannot proceed back to the alv list-

...

case u_ucomm.

when '&ADD'.

call screen '0100'.

...

endcase.

MODULE status_0100 OUTPUT.

SET PF-STATUS '0100'.
SET TITLEBAR '0100' WITH text-400. "Anlage neues Material für Z---

ENDMODULE.

MODULE fill_0100 OUTPUT.

CLEAR t_tab5[].

CLEAR t_fieldcat[].
clear s_fieldcat.
s_fieldcat-fieldname = 'MATNR'.
s_fieldcat-ref_table = 'Z---.
s_fieldcat-edit = 'X'.

clear s_fieldcat.
s_fieldcat-fieldname = 'MATKAT'.
s_fieldcat-ref_table = 'Z---'.
s_fieldcat-edit = 'X'.

clear s_fieldcat.
s_fieldcat-fieldname = 'PRIOV'.
s_fieldcat-ref_table = 'Z---'.
s_fieldcat-edit = 'X'.

clear s_fieldcat.
s_fieldcat-fieldname = 'PRIOV'.
s_fieldcat-ref_table = 'Z---'.
s_fieldcat-edit = 'X'.

MOVE-CORRESPONDING t_tab5 to t_tab[].


ENDMODULE.

MODULE exit_0100 INPUT.

case ok_0100.
WHEN 'BACK'.
MOVE-CORRESPONDING t_tab5 to t_tab[].
LEAVE TO SCREEN 0.
WHEN 'EXIT'.
LEAVE PROGRAM.
WHEN 'CANCEL'.
LEAVE TO SCREEN 0100.

ENDCASE.

ENDMODULE.

4 REPLIES 4

raymond_giuseppi
Active Contributor
  • No explicit FIELD statement, so I suggest you first read some documentation like Data transport at point of time PAI (look for FIELD and TABLES statements in online help or your Abap course)
  • Else if the values are correctly moved to Abap program what code follows the CALL SCREEN?
  • Also did you use the STARTING AT option in the CALL SCREEN statement (does it appear as a POPUP) ?

Could you give more information on which fields are defined in the screen, in the program and how you manage the insertion of the new record in the internal table before refreshing the ALV display?

Regards,
Raymond

Former Member
0 Kudos

I will not post my 1000+ lines coding here. It's a Z programm for MM .

Your comment seems like spamming.

Former Member
0 Kudos

I don't care. the new community is really sh*.

never touch a running system

JL23
Active Contributor

Haha - "never touch a running system" - if that slogan would be right then you had no job.