Quantcast
Channel: SCN: Message List - User Interface Development in ABAP
Viewing all 1038 articles
Browse latest View live

Re: Classical report design

$
0
0

Hi,

Since you are new to abap, I'll try a more simple approach.

I think you should consider making a module pool for your program.

 

Go to se80 and create a program, module pool.

 

Inside that program, you will be able to create screens.

 

For example, screen 0100 will be your selection parameters screen (With your radio buttons and table grids). After the user fill this screen and run your program, you will have to write code in the PAI of the screen flow, calling your process code, or a new screen.

 

You can find lots of information of ABAP Module Pools on google.

 

 

 

Thales Schmidt


Re: ALV delta refresh possibility

$
0
0

Hi Bulent,

 

Did you find a way to update single line in ALV? Thanks.

Re: Dynamically assign function keys to gui-status

$
0
0

Hi Kiran,

 

you mention that it is possible to change function codes in a gui status dynamically.

 

Cann you give me a hit how that is possible?

 

Thank you very much,

 

Gianpietro

Email Program - Batch Job Completion

$
0
0

Hi

 

My requirement is that I have a batch program and as soon as it is completed, an email needs to be sent to user informing that the job has been completed.

 

My questions are below

 

1. Do i need to create a Z program that sends email and add it in the steps of the batch job ?

 

2. Is there a possibility of any alert settings done for specific job to trigger email rather than Z program?

 

3. Can I develop the Z program as generic so that it can be added as a step to any batch job and that it needs to capture the batcj job name and send it in email? if so, how do i do this

 

4. Any other ideas are also appreciated.

 

Regards

Sam

Re: Webapplication UI5 or XSapp

Re: UI5_731 vs UI2_731 on ECC 6.0 Ehp6 - System

$
0
0

Hi Srinivas,

 

I have the same question. You could solve this?

 

Regards,

Ítalo Teixeira

Dynamic documents: disable two input fields results into error

$
0
0

Hello experts,

 

I used the first time dynamic documents, to put input fields into containers. If i want to disable both input fields with the Method set_display, the one on the bottom will not be rendered.

 

Unbenannt.PNG

If i disable only one input field, both will be displayed correctly. I searched for sap notes already, but couldn't find one.

 

Here is the code i'm using:

 

METHOD initialize_document.

  DATA: lo_form  TYPE REF TO cl_dd_form_area,

        lo_input TYPE REF TO cl_dd_input_element.

 

  DATA: lo_table    TYPE REF TO cl_dd_table_element,

        lo_column_1 TYPE REF TO cl_dd_area,

        lo_column_2 TYPE REF TO cl_dd_area.

 

  CREATE OBJECT go_document.

 

  CALL METHOD go_document->display_document

    EXPORTING

      parent = go_split->get_container( row    = 1

                                        column = 1 ).

 

* Create Table

  CALL METHOD go_document->add_table

    EXPORTING

      no_of_columns = 2

      border        = '0'

    IMPORTING

      table         = lo_table.

 

  CALL METHOD lo_table->add_column

    IMPORTING

      column = lo_column_1.

 

  CALL METHOD lo_table->add_column

    IMPORTING

      column = lo_column_2.

 

* Create first row

  CALL METHOD lo_column_1->add_text

    EXPORTING

      text = 'Gruppe'(003).

 

  CALL METHOD lo_column_1->add_gap

    EXPORTING

      width = 2.

 

  CALL METHOD lo_column_2->add_form

    IMPORTING

      formarea = lo_form.

 

  CALL METHOD lo_form->add_input_element

    EXPORTING

      value         = go_gname->get_gname( )

      name          = 'GNAME'

      size          = 30

      maxlength     = 20

    IMPORTING

      input_element = lo_input.

 

  CALL METHOD lo_input->set_display

    EXPORTING

      disabled = abap_true.

 

* Create second row

  CALL METHOD lo_table->new_row.

 

  CALL METHOD lo_column_1->add_text

    EXPORTING

      text = 'Bezeichnung'(001).

 

  CALL METHOD lo_column_1->add_gap

    EXPORTING

      width = 2.

 

  CALL METHOD lo_column_2->add_form

    IMPORTING

      formarea = go_form.

 

  CALL METHOD go_form->add_input_element

    EXPORTING

      value         = go_gname->get_text( )

      name          = 'TEXT'

      size          = 90

      maxlength     = 60

    IMPORTING

      input_element = go_input.

 

  CALL METHOD go_input->set_display

    EXPORTING

      disabled = abap_true.

 

* Merge and display document

  CALL METHOD go_document->merge_document.

 

  CALL METHOD go_document->display_document

    EXPORTING

      reuse_control      = abap_true

      reuse_registration = abap_true.

 

* Hide document border

  CALL METHOD go_document->html_control->set_ui_flag

    EXPORTING

      uiflag = cl_gui_html_viewer=>uiflag_no3dborder.

ENDMETHOD.

Re: Custom Program in BTE

$
0
0

BTE will execute FM and only FM. So wrap the report call in a FM. But, insure the BTE is called in a process/transaction state that allows use of SUBMIT (e.g. not during update task) also don't use any not allowed statement in this case?

 

Regards,

Raymond


CONVERT SAP SCRIPT TO PDF AND SEND MAIL

$
0
0

Hi,

 

I got the requirement to convert a SAP Script to PDF and a Mail to SOST.

 

But for me Mail is going to SOST, And the PDF options came . But when i click On PDF i couldn't open the Form. Its shows some Error.

 

 

  CALL FUNCTION 'CLOSE_FORM'
IMPORTING
RESULT 
= RESULT
tables
otfdata
= lt_otf
EXCEPTIONS
OTHERS  = 1.

************************************************************************************
** Convert the OTF File Obtained in a PDF File
************************************************************************************
data: lv_binstr type XSTRING.

CALL FUNCTION 'CONVERT_OTF'
EXPORTING
FORMAT                      = 'PDF'
MAX_LINEWIDTH              
= 132
PDF_DELETE_OTFTAB          
= ' '
IMPORTING
bin_filesize               
= lv_file_size
bin_file                   
= lv_binstr
TABLES
otf                        
= lt_otf
lines                                                 = lt_pdf
.

************************************************************************************
** Convert the Xstring To BINARY
************************************************************************************
CALL FUNCTION 'SCMS_XSTRING_TO_BINARY'
EXPORTING
buffer     = lv_binstr
TABLES
binary_tab
= lt_binary_tab.




CALL FUNCTION 'SO_NEW_DOCUMENT_ATT_SEND_API1'
EXPORTING
document_data                   
= ls_gd_doc_data
PUT_IN_OUTBOX                   
= 'X'
COMMIT_WORK                     
= 'X'
tables
packing_list                    
= lt_packing_list
OBJECT_HEADER                   
= lt_mail_head
CONTENTS_BIN                    
= lt_mail_bin
CONTENTS_TXT                    
= lt_mailtext
contents_hex                    
= lt_binary_tab
receivers                       
= lt_receivers
EXCEPTIONS
TOO_MANY_RECEIVERS              
= 1
DOCUMENT_NOT_SENT               
= 2
DOCUMENT_TYPE_NOT_EXIST         
= 3
OPERATION_NO_AUTHORIZATION      
= 4
PARAMETER_ERROR                 
= 5
X_ERROR                         
= 6
ENQUEUE_ERROR                   
= 7
OTHERS                           = 8
.
ENDFORM.                    " ZSEND_MAIL

 

 

 

 

 

 

Regards,

Sadiq K

Re: GOS: How to display attachment?

$
0
0

Hello,

 

 

I have just started exploring GOS and i have a doubt.

Why does the file get saved on the local disk when I use the method ' display_attachment'?

Is there a way where i can delete the saved file from the local disk?

 

Thanks,

Ninad.

DYNP_VALUES_READ & DYNP_VALUES_UPDATE at Selection-Screen Output

$
0
0

Hello Friends

 

I've noticed that if I invoke either of FM's DYNP_VALUES_READ & DYNP_VALUES_UPDATE that they do not work during the event At Selection-Screen Output.

 

The Scenario

 

I created a class that provides F4 help to the user to open and/or save files either to the file server or on the local machine.  When the user invokes F4 help, the F4 help object already knows which file the user is asking help for.  At this time, the object invokes DYNP_VALUES_READ and pre-populates fields in a dialog box.  When the dialog step is complete, the object invokes DYNP_VALUES_UPDATE to return the values back to the selection screen.

 

So far so good.

 

The Problem

 

We use logical files for files located on the file server.  What I would like to do is pretty much the same thing as above except without the dialog step in between.  In other words, take the screen defaults (i.e. logical file + filename) determine the full path using FILE_GET_NAME and populate the full path on the screen.  If the user wants to change this later, s/he can do so using F4 help.

 

But when I use DYNP_VALUES_READ during At Selection-Screen Output it doesn't return the current screen parameter values, so I replaced it with FM RS_REFRESH_FROM_SELECTOPTIONS.  This works, but then DYNP_VALUES_UPDATE did not update the screen even though I can see the internal table for DYNPFIELDS is populated.  The function appears to work correctly and SY-SUBRC = 0, but the field is blank.

 

I know the code works because I invoke the same methods during F4 and this does populate the screen.

 

Is what I am doing not possible during At Selection-Screen Output?

How I can use one submit report with an specific Tcode when exists more than one for same report?

$
0
0

Hi,

 

I have one report (rmcb0300) with five tcodes differently and tcode by default when I execute by SE38 is MCBE. I need execute the tcode MC.9 when I use the submit report (SUBMIT rmcb0300 EXPORTING LIST TO MEMORY  AND RETURN), but I  can't this.

Someone have one idea whow can do it?

 

Regards,


Sérgio Silva

ORDCHG Extension Idoc problem

$
0
0

Hi SAP GURU'S

 

I did below steps for extension of ORDCHG Message type 

 

 

 

1. WE31 - Created A segment(YTEST) with additional fields.

2. WE20 - Created the Extension(ZORDERS05) for the given Basic type ORDERS05.

        2.1    added the custom segment(YTEST) as the child segment to the segment ( E1EDP01)

 

3. Released the custom segment (YTEST) and the Extension (ZORDERS05).

 

4. WE82 - Assigned Basic type to extension / messages( For Both messages ORDCHG&ORDERS)

 

5. WE30 - Checked and Transported IDoc extension

                 5.1  Given the Extension Name(ZORDERS05)

                 5.2 In the menu Path :  Development Object -- >Check (Ensure that there are no errors or warnings)

 

6. WE20 - Now in the Partner Profile  added the Extension(ZORDERS05) in the Message control data and Saved it(For Both messages ORDCHG&ORDERS).

 

 

I added code In BADI (IDOC_DATA_INSERT)  for YTEST Segment .

 

case control-direct.
     when '1'.                         " Outbound
       case control-rcvprn .
         when 'XXXXX'.             " Partenr
           case control-mestyp.
                 when 'ORDERS' or 'ORDCHG'.           " Message type


If Control-cimtyp = 'ZORDERS05.


loop at data into ls_data where segnam = 'E1EDP01'.
                     ls_seg_num-segnum = ls_data-segnum.
                     append ls_seg_num to lt_seg_num .
                   endloop .

                   lv_count = 1.
                   loop at lt_ekpo into ls_ekpo.
                     read table lt_seg_num into ls_seg_num index lv_count.
* filling Maximo PR field name and value
                     ls_y1mm_maximo_pr-item = ls_ekpo-bnfpo.
                     ls_y1mm_maximo_pr-bednr = ls_ekpo-bednr.
                     ls_y1mm_maximo_pr-banfn = ls_ekpo-banfn.

                     clear ls_new_segment1.
* Data inserting into zsegments
                     ls_new_segment1-segnam = lco_zsegment1.
                     ls_new_segment1-counter = '000' .
                     ls_new_segment1-sdata = ls_y1mm_maximo_pr.
                     ls_new_segment1-segnum = ls_seg_num-segnum.

                     if ls_new_segment1  is not initial.
                       have_to_change = 'X'.
                       append ls_new_segment1 to new_entries.
                     endif.
                     clear : ls_y1mm_maximo_pr.
                     lv_count = lv_count + 1.
                   endloop.


     Endif.
Endcase.


Note : This is working for PO Creation( ORDERS Msg) , I can See the "Control-cimtyp = 'ZORDERS05'"  , But it is n

ot working for ORDCHG Msg type , I did the above config for  both message types .


When ever PO change I could nt see the extension Idoc( ZORDERS05) , Even in WE05 Tcode , But Idoc is tiggering with out adding adding additional segment(YTEST) .


Please kindly help me out .,


Thanks in advance,

Krishna Kothaluru.


               


Re: Error: input/output field not defined in subscreen.

$
0
0

hi Aris,

go to your main program and make sure that you have declared the variable MARA-ZZPARENT.

Regards

Screen text erea

$
0
0

Hi,

I using screen text erea for application!

Screen text erea used to import value.

When I first entered it ok, but the second entry, the old value of the first not delete.

I have used the class to remove but it still can not delete the original input value!


Re: Screen text erea

$
0
0

Did you use a  set_text_as_r3table or similar method in the PBO, else can you elaborate on your requirement and actual methods you call?

 

Regards,

Raymond

Re: Screen text erea

$
0
0

I used set_text_as_r3table but it still can not delete the old values!

Re: Screen text erea

$
0
0

So you have to post part of your code as this method (with an empty internal table) should clear the area. (PBO logic and related statements called in Modules)

Re: Screen text erea

$
0
0

At the bottom is the code that I use to work with text erea. I used the clear function object as well as clear text, but it still can not delete the old value!

CLEAR EDITOR1.

   CREATE OBJECT EDITOR1

         EXPORTING

          PARENT = TEXTEDIT_CUSTOM_CONTAINER

          WORDWRAP_MODE =

*               cl_gui_textedit=>wordwrap_off

             CL_GUI_TEXTEDIT=>WORDWRAP_AT_FIXED_POSITION

*              cl_gui_textedit=>WORDWRAP_AT_WINDOWBORDER

          WORDWRAP_POSITION = LINE_LENGTH

          WORDWRAP_TO_LINEBREAK_MODE = CL_GUI_TEXTEDIT=>TRUE.

 

   CALL METHOD EDITOR1->DELETE_TEXT.

 

   LS_MYTB-LINE_TEXT = GS_SCREEN-CONTENT01.

   APPEND LS_MYTB TO MYTABLE1.

   CALL METHOD EDITOR1->SET_TEXT_AS_R3TABLE

     EXPORTING

       TABLE = MYTABLE1.

How to provide collapse / expand functionality to alv grid display

$
0
0

I want Icon in alv grid display as one of the column and when i click on that icon i works same as like like expand / collapse option.Suppose i want to display header and item details of po ,i want alv grid with header details with one column as icon when i click on that icon it wil display related item details based on header on same grid display and again i click on that icon data will disappear.

Viewing all 1038 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>