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

Shortdump whenever button is clicked

Former Member
0 Likes
868

Hi all,

I am writing a abap program interface to allow users to click on button to access to z-table maintenace view table.

However I got a shortdump whenever button is clicked. Anyone knows what is wrong?

Here is my Error Analysis during Runtime:

You attempted to start the ABAP/4 program "SAPLZVSPP_TEST" with SUBMIT, but

the

attributes specify this program as type "F" instead of "1". You can

only start programs of type 1 with SUBMIT.

The code in my REPORT is: -


REPORT  SAPMZPPP_TEST_RPT.

INCLUDE ZPPP_TEST_RPT_TOP.
INCLUDE ZPPP_TEST_RPT_SEL.
INCLUDE ZPPP_TEST_RPT_F01.

INITIALIZATION.

AT SELECTION-SCREEN OUTPUT.
  PERFORM prepare_monitor.

AT SELECTION-SCREEN.
  PERFORM process_input

Code in ZPPP_TEST_RPT_F01 : -


FORM process_input.
  DATA: gc_progname_pick TYPE sy-repid,
        lv_report        TYPE rsvar-report.
  gf_okcode = sscrfields-ucomm.

  CASE gf_okcode.
    gc_progname_pick = 'SAPLZVSPP_TEST'.
    lv_report   = gc_progname_pick.

    WHEN 'TEST'.
      gf_mode = 'TEST'.
      SUBMIT (lv_report) VIA SELECTION-SCREEN
        WITH p_mode = gf_mode
         AND RETURN.
  ENDCASE.
ENDFORM.

Thanks in advance.

1 ACCEPTED SOLUTION
Read only

uwe_schieferstein
Active Contributor
0 Likes
841

Hello

Using SUBMIT you can only start "executable programs" (= '1'). In your case you tried to call a function module (type = 'F') via SUBMIT which does not work.

Regards

Uwe

7 REPLIES 7
Read only

uwe_schieferstein
Active Contributor
0 Likes
842

Hello

Using SUBMIT you can only start "executable programs" (= '1'). In your case you tried to call a function module (type = 'F') via SUBMIT which does not work.

Regards

Uwe

Read only

0 Likes
841

Hi Uwe,

Thanks for your information. Is there anyway to solve my problem to display the maintenance view table using this button click?

The reason why I implement this button click interface is because to ease the users without memorize all the transaction codes.

Read only

0 Likes
841

HI myahsam wong,

I would refer in this case to create a transaction code for the view and call that transaction code from your report while clicking on button.

Go to SE93-> create a transaction code-> click on Create button.

Enter the description and select the radio button last one with parameter. Select default transaction code as SM30 and select skip initial screen. Scroll down and enter in the table control VIEWNAME as your maintenance view and UPDATE is equal to X.

Once it is done activate it and call from your report.

Thanks & Regards,

Nagaraj Kalbavi

Read only

0 Likes
841

I have actually setup a customized transaction code for the maintenance view table.

In my example showing above, I should put the transaction code or the program name?


  CASE gf_okcode.
    gc_progname_pick = 'SAPLZVSPP_TEST'. " put transaction code or program name? 
    lv_report   = gc_progname_pick.

    WHEN 'TEST'.
      gf_mode = 'TEST'.
      SUBMIT (lv_report) VIA SELECTION-SCREEN
        WITH p_mode = gf_mode
         AND RETURN.
  ENDCASE.

Please advice.

Read only

0 Likes
841

Hi WOng,

USe Transaction code instead of program name. Instead of submit use call transaction. hOPE IT RESOLVES YOUR PROBLEM.

Thanks & Regards,

Read only

0 Likes
841

Hi all,

At last, I found that I should use this method to call via a button:

CALL TRANSACTION 'ZSM30_TEST' AND SKIP FIRST SCREEN.

Thanks to all for the inputs.

Read only

Former Member
0 Likes
841

Hi,

I suggest you debug the transaction SM30 (Table/View) Maintenance and see how it is done in your particular version.

Either that of code a call transaction to SM30 and skip the first screen.

Cheers

David Cooper