Ir al contenido principal

Z_VERIFICA_USER_EXIT

report  z_verifica_user_exit line-size 140 no standard page heading.
 
*======================================================================*
* PROGRAMA...: Z_VERIFICA_USER_EXIT
*----------------------------------------------------------------------*
* OBJETIVO...: REVISA USER-EXITS EN UNA DETERMINADA TRANSACCION  O
*              PROGRAMA.                                               *
*----------------------------------------------------------------------*
* PARAMETROS.: P_PROG  = NOMBRE DE PROGRAMA A SER REVISADO
*              P_TCODE = NOMBRE DE TRANSACCION A SER REVISADA
*              OBS.: UM DOS DOIS PARÂMETROS ACIMA DEVE SER ESPECIFICADO
*
*              P_INCL  = DETERMINA SI LA REVISION DEBE TENER EN
*                        CONSIDERACION LOS INCLUDES.
*              P_FUNC  = DETERMINA SI LA REVISION DEBE TENER EN
*                        CONSIDERACION LAS FUNCIONES.
*              P_SUBMIT= DETERMINA SI LA REVISION DEBE TENER EN
*                        CONSIDERACION LOS DEMAS PROGRAMAS LLAMADOS
*                        POR SUBMIT.
*
*              P_NIVEL = DETERMINA EL NIVEL DE LA REVISION HECHA DENTRO
*                        DE LOS INCLUDES, FUNCIONES Y DEMAS PROGRAMAS.
*                        EN EL NIVEL 1 SOLAMENTE SERA TOMADOS EN
*                        CONSIDERACION EN EL PROGRAMA RAIZ. EN EL NIVEL
*                        2 SE REVISARAN LOS INCLUDES, FUNCIONES DENTRO
*                        LOS INCLUDES, FUNCIONES DEL NIVEL 1 Y ASI
*                        SUCESIVAMENTE.
*
*              OBS.: EN EL PARAMETRO P_NIVEL INFORMAR VALORES BAJOS,
*              YA QUE A MAYOR NUMERO, MAYOR CANTIDAD DE CODIGO
*              SERA ANALIZADO
*----------------------------------------------------------------------*
*
*======================================================================*
*----------------------------------------------------------------------*
* CONSTANTS
*----------------------------------------------------------------------*
constants: c_user_exit(22) type c value 'USEREXIT',
           c_enhance(22)   type c value 'CALL CUSTOMER-FUNCTION',
           c_funcao_1(13)  type c value 'CALLFUNCTION''',
           c_funcao_2(13)  type c value 'CALL FUNCTION',
           c_include(07)   type c value 'INCLUDE',
           c_submit(06)    type c value 'SUBMIT',
           c_comentario    type c value '*',
           c_ponto         type c value '.',
           c_aspa          type c value '''',
           c_x             type c value 'X'.
 
*----------------------------------------------------------------------*
* TABLAS INTERNAS
*----------------------------------------------------------------------*
data: begin of ti_programa occurs 0,
            codigo_fonte like rssource-line,
      end   of ti_programa.
 
data: begin of ti_includes occurs 0,
            nome     like sy-repid,
            nivel(2) type n,
      end   of ti_includes.
 
data: begin of ti_user_exit occurs 0,
            programa     like sy-repid,
            linha(10)    type n,
            codigo_fonte like rssource-line,
            nivel(2)     type n,
      end   of ti_user_exit.
 
*----------------------------------------------------------------------*
* VARIABLE GLOBALES
*----------------------------------------------------------------------*
data: vg_caracter     type c,
      vg_palavra(50)  type c,
      vg_inicial      like sy-index,
      vg_conta_aspa   type n,
      vg_pname like   tfdir-pname,
      vg_texto(50)    type c,
      vg_contador     like sy-tfill,
      vg_nivel(2)     type n,
      vg_ini_contagem type c," INDICA QUE DEVE SER INICIADA A CONTADOR
      vg_conta_espaco type n." TOTAL DE ESPACIOS ( MÁXIMO 2 )
 
*----------------------------------------------------------------------*
* PARAMETROS
*----------------------------------------------------------------------*
 
*- DATOS OBLIGATORIOS.
selection-screen begin of block bl01 with frame title text-001 .
parameters: p_prog  like sy-repid,
            p_tcode like sy-tcode.
selection-screen end   of block bl01.
 
*- DATOS OPCIONALES.
selection-screen begin of block bl02 with frame title text-002.
parameters: p_incl      as checkbox,
            p_func      as checkbox,
            p_submit    as checkbox,
            p_nivel(2) type n.
selection-screen end   of block bl02.
 
*----------------------------------------------------------------------*
* INICIO
*----------------------------------------------------------------------*
start-of-selection.
'
'
*- CONSISTÊNCIAS DOS PARÂMETROS.
  perform consisti_parametros.
 
*- INICIALIZA TABELA.
  perform inicializa_tabela.
 
*- VERIFICA SE NO PROGRAMA EXISTE ALGUM INCLUDE,FUNÇÃO OU SUBMIT.
  perform verifica_include_funcao_submit.
 
*- ANALISA OS INCLUDES E PROCURA POR USER EXIT.
  perform procura_user_exit.
 
*- ANALISA OS INCLUDES E PROCURA POR USER EXIT.
  perform procura_enhancements.
 
*- EXIBE TODAS USER EXIT ENCONTRADAS.
  perform exibe_user_exit.
 
*----------------------------------------------------------------------*
* FIM
*----------------------------------------------------------------------*
end-of-selection.
'
*&---------------------------------------------------------------------*
*&      Form  PROCURA_USER_EXIT
*&---------------------------------------------------------------------*
*       text
*----------------------------------------------------------------------*
*  -->  p1        text
*  <--  p2        text
*----------------------------------------------------------------------*
form procura_user_exit.
'
*- VERIFICA SE NOS INCLUDES SELECIONADOS EXISTEM USER EXITS.
  loop at ti_includes.
 
*- ESVAZIA TABELA INTERNA.
    refresh ti_programa.
 
*- REALIZA LEITURA DO INCLUDE ARMAZENANDO-O EM TABELA INTERNA
    read report ti_includes-nome into ti_programa.
 
    loop at ti_programa.
 
*- VERIFICA SE NA LINHA DO PROGRAMA EXISTE ALGUM INCLUDE.
      search ti_programa-codigo_fonte for c_user_exit.
*- SE ENCONTROU INCLUDE E SE A LINHA NÃO ESTÁ COMENTADA...
      if  sy-subrc eq 0
      and ti_programa-codigo_fonte+0(1) ne c_comentario.
        clear ti_user_exit.
*- REMOVE ESPAÇOS NO INÍCIO DA STRING.
        shift ti_programa-codigo_fonte left deleting leading space.
        move: ti_includes-nome         to ti_user_exit-programa,
              sy-tabix                 to ti_user_exit-linha,
              ti_programa-codigo_fonte to ti_user_exit-codigo_fonte,
              ti_includes-nivel        to ti_user_exit-nivel.
        append ti_user_exit.
      endif.
 
    endloop.
 
  endloop.
 
endform." PROCURA_USER_EXIT
'
*&---------------------------------------------------------------------*
*&      Form  PROCURA_ENHANCEMENTS
*&---------------------------------------------------------------------*
*       text
*----------------------------------------------------------------------*
*  -->  p1        text
*  <--  p2        text
*----------------------------------------------------------------------*
form procura_enhancements.
'
*- VERIFICA SE NOS INCLUDES SELECIONADOS EXISTEM USER EXITS.
  loop at ti_includes.
 
*- ESVAZIA TABELA INTERNA.
    refresh ti_programa.
 
*- REALIZA LEITURA DO INCLUDE ARMAZENANDO-O EM TABELA INTERNA
    read report ti_includes-nome into ti_programa.
 
    loop at ti_programa.
 
*- VERIFICA SE NA LINHA DO PROGRAMA EXISTE ALGUM INCLUDE.
      search ti_programa-codigo_fonte for c_enhance.
*- SE ENCONTROU INCLUDE E SE A LINHA NÃO ESTÁ COMENTADA...
      if  sy-subrc eq 0
      and ti_programa-codigo_fonte+0(1) ne c_comentario.
        clear ti_user_exit.
*- REMOVE ESPAÇOS NO INÍCIO DA STRING.
        shift ti_programa-codigo_fonte left deleting leading space.
        move: ti_includes-nome         to ti_user_exit-programa,
              sy-tabix                 to ti_user_exit-linha,
              ti_programa-codigo_fonte to ti_user_exit-codigo_fonte,
              ti_includes-nivel        to ti_user_exit-nivel.
        append ti_user_exit.
      endif.
 
    endloop.
 
  endloop.
 
endform." PROCURA_ENHANCEMENTS
'
*&---------------------------------------------------------------------*
*&      Form  EXIBE_USER_EXIT
*&---------------------------------------------------------------------*
*       text
*----------------------------------------------------------------------*
*  -->  p1        text
*  <--  p2        text
*----------------------------------------------------------------------*
form exibe_user_exit.
  perform cabecalho.
  perform user_exit_nao_encontrada.
  perform lista_user_exit_encontrada.
  perform rodape.
endform." EXIBE_USER_EXIT
'
*&---------------------------------------------------------------------*
*&      Form  PROCURA_INCLUDE
*&---------------------------------------------------------------------*
*       text
*----------------------------------------------------------------------*
*  -->  p1        text
*  <--  p2        text
*----------------------------------------------------------------------*
form procura_include.
'
  clear vg_palavra.
*- VERIFICA SE NA LINHA DO PROGRAMA EXISTE ALGUM INCLUDE.
  search ti_programa-codigo_fonte for c_include.
*- SE ENCONTROU INCLUDE E SE A LINHA NÃO ESTÁ COMENTADA...
  if  sy-subrc eq 0
  and ti_programa-codigo_fonte+0(1) ne c_comentario.
*- VERIFICA TODOS OS 72 CARACTERES DA LINHA PARA MONTAR NOME DO INCLUDE
    do 72 times.
      vg_inicial = sy-index - 1.
      move ti_programa-codigo_fonte+vg_inicial(1) to vg_caracter.
      if not vg_caracter is initial.
*- VERIFICA SE NÃO É FIM DO COMANDO.
        if vg_caracter eq c_ponto.
          exit.
        endif.
*- MONTA PALAVRA.
        concatenate vg_palavra vg_caracter into vg_palavra.
*- CONVERTE PARA MAÍUSCULA PARA FUTURA COMPARAÇÃO.
        translate vg_palavra to upper case.
*- SE ENCONTROU ALGUM INCLUDE
        if vg_palavra eq c_include.
          clear vg_palavra.
        endif.
      endif.
    enddo.
*- SALVA NOME DO INCLUDE PARA FUTURA PESQUISA POR USER EXIT.
    read table ti_includes with key nome = vg_palavra.
    if not sy-subrc is initial.
      if vg_nivel le p_nivel.
        move: vg_palavra to ti_includes-nome,
              vg_nivel   to ti_includes-nivel.
        append ti_includes.
      endif.
    endif.
 
  endif.
 
endform." PROCURA_INCLUDE
'
*&---------------------------------------------------------------------*
*&      Form  PROCURA_FUNCAO
*&---------------------------------------------------------------------*
*       text
*----------------------------------------------------------------------*
*  -->  p1        text
*  <--  p2        text
*----------------------------------------------------------------------*
form procura_funcao.
'
  clear: vg_conta_aspa,
         vg_palavra.
 
*- VERIFICA SE NA LINHA DO PROGRAMA EXISTE ALGUM INCLUDE.
  search ti_programa-codigo_fonte for c_funcao_2.
*- SE ENCONTROU INCLUDE E SE A LINHA NÃO ESTÁ COMENTADA...
  if  sy-subrc eq 0
  and ti_programa-codigo_fonte+0(1) ne c_comentario.
*- VERIFICA TODOS OS 72 CARACTERES DA LINHA PARA MONTAR NOME DO INCLUDE
    do 72 times.
      vg_inicial = sy-index - 1.
      move ti_programa-codigo_fonte+vg_inicial(1) to vg_caracter.
      if not vg_caracter is initial.
*- VERIFICA SE NÃO É FIM DO COMANDO.
        if vg_caracter eq c_aspa.
          add 1 to vg_conta_aspa.
          if vg_conta_aspa eq 2.
            exit.
          endif.
        endif.
*- MONTA PALAVRA.
        concatenate vg_palavra vg_caracter into vg_palavra.
*- CONVERTE PARA MAÍUSCULA PARA FUTURA COMPARAÇÃO.
        translate vg_palavra to upper case.
*- SE ENCONTROU ALGUM INCLUDE
        if vg_palavra eq c_funcao_1.
          clear vg_palavra.
        endif.
      endif.
    enddo.
*- PESQUISA NOME DA FUNÇÃO PARA FUTURA PESQUISA POR USER EXIT.
    clear vg_pname.
    select single pname
           into   vg_pname
           from   tfdir
           where  funcname eq vg_palavra.
    if sy-subrc eq 0.
 
      read table ti_includes with key nome = vg_pname.
      if not sy-subrc is initial.
        if vg_nivel le p_nivel.
          move: vg_pname to ti_includes-nome,
                vg_nivel to ti_includes-nivel.
          append ti_includes.
        endif.
      endif.
 
    endif.
  endif.
 
endform." PROCURA_FUNCAO
'
*&---------------------------------------------------------------------*
*&      Form  VERIFICA_INCLUDE_FUNCAO_SUBMIT
*&---------------------------------------------------------------------*
*       text
*----------------------------------------------------------------------*
*  -->  p1        text
*  <--  p2        text
*----------------------------------------------------------------------*
form verifica_include_funcao_submit.
'
  loop at ti_includes.
 
    add 1 to vg_contador.
    describe table ti_includes.
    perform evitar_time_out using sy-tfill.
    move ti_includes-nivel to vg_nivel.
    add 1 to vg_nivel.
 
*- ESVAZIA TABELA INTERNA.
    refresh ti_programa.
 
*- REALIZA LEITURA DO INCLUDE/FUNÇÃO ARMAZENANDO EM TABELA INTERNA
    read report ti_includes-nome into ti_programa.
 
    loop at ti_programa.
 
*- PROCURA POR INCLUDES.
      if p_incl eq c_x.
        perform procura_include.
      endif.
*- PROCURA POR FUNÇÃO.
      if p_func eq c_x.
        perform procura_funcao.
      endif.
*- PROCURA POR SUBMIT.
      if p_submit eq c_x.
        perform procura_submit.
      endif.
 
    endloop.
 
  endloop.
 
endform." VERIFICA_INCLUDE_FUNCAO_SUBMIT
'
*&---------------------------------------------------------------------*
*&      Form  EVITAR_TIME_OUT
*&---------------------------------------------------------------------*
*       text
*----------------------------------------------------------------------*
*      -->P_SY_TFILL  text
*      -->P_SY_SUBRC  text
*----------------------------------------------------------------------*
form evitar_time_out using    p_sy_tfill.
'
  data: vl_total(10) type n,
        vl_atual(10) type n.
 
  move: p_sy_tfill  to vl_total,
        vg_contador to vl_atual.
 
  concatenate 'Total:' vl_total '-' 'Atual:' vl_atual
         into vg_texto
         separated by space.
 
  CALL FUNCTION 'SAPGUI_PROGRESS_INDICATOR'
       EXPORTING
            text = vg_texto.
 
 
endform." EVITAR_TIME_OUT
'
*&---------------------------------------------------------------------*
*&      Form  PROCURA_SUBMIT
*&---------------------------------------------------------------------*
*       text
*----------------------------------------------------------------------*
*  -->  p1        text
*  <--  p2        text
*----------------------------------------------------------------------*
form procura_submit.
'
  clear: vg_conta_espaco, vg_palavra, vg_ini_contagem.
 
*- VERIFICA SE NA LINHA DO PROGRAMA EXISTE ALGUM INCLUDE.
  search ti_programa-codigo_fonte for c_submit.
*- SE ENCONTROU INCLUDE E SE A LINHA NÃO ESTÁ COMENTADA...
  if  sy-subrc eq 0
  and ti_programa-codigo_fonte+0(1) ne c_comentario.
*- VERIFICA TODOS OS 72 CARACTERES DA LINHA PARA MONTAR NOME DO INCLUDE
    do 72 times.
      vg_inicial = sy-index - 1.
      move ti_programa-codigo_fonte+vg_inicial(1) to vg_caracter.
      if vg_ini_contagem eq c_x and vg_caracter is initial.
        add 1 to vg_conta_espaco.
      endif.
 
      if not vg_caracter is initial.
        move c_x to vg_ini_contagem.
        if vg_caracter eq c_ponto.
          exit.
        endif.
*- MONTA PALAVRA.
        if vg_conta_espaco lt 2.
          concatenate vg_palavra vg_caracter into vg_palavra.
*- CONVERTE PARA MAÍUSCULA PARA FUTURA COMPARAÇÃO.
          translate vg_palavra to upper case.
*- SE ENCONTROU ALGUM INCLUDE
          if vg_palavra eq c_submit.
            clear vg_palavra.
          endif.
        else.
          exit.
        endif.
      endif.
    enddo.
*- PESQUISA NOME DA FUNÇÃO PARA FUTURA PESQUISA POR USER EXIT.
    read table ti_includes with key nome = vg_palavra.
    if not sy-subrc is initial.
      if vg_nivel le p_nivel.
        move: vg_palavra to ti_includes-nome,
              vg_nivel   to ti_includes-nivel.
        append ti_includes.
      endif.
    endif.
  endif.
 
 
endform." PROCURA_SUBMIT
'
*&---------------------------------------------------------------------*
*&      Form  CONSISTI_PARAMETROS
*&---------------------------------------------------------------------*
*       text
*----------------------------------------------------------------------*
*  -->  p1        text
*  <--  p2        text
*----------------------------------------------------------------------*
form consisti_parametros.
'
  if p_nivel is initial.
    move 1 to p_nivel.
  endif.
 
  if p_prog is initial and p_tcode is initial.
*- NOME DO PROGRAMA E NOME DA TRANSAÇÃO NÃO PODEM SER NULOS. UM DELES
*- DEVE SER INFORMADO.
    message id 'ZF' type 'I' number '000' with text-003.
    stop.
  endif.
 
  if not p_prog is initial and not p_tcode is initial.
*- SOLICITA AO USUÁRIO PARA INFORMAR O NOME DO PROGRAMA OU DA TRANSAÇÃO.
    message id 'ZF' type 'I' number '000' with text-004.
    stop.
  endif.
 
endform." CONSISTI_PARAMETROS
'
*&---------------------------------------------------------------------*
*&      Form  INICIALIZA_TABELA
*&---------------------------------------------------------------------*
*       text
*----------------------------------------------------------------------*
*  -->  p1        text
*  <--  p2        text
*----------------------------------------------------------------------*
form inicializa_tabela.
  data vl_pgmna like tstc-pgmna.
 
  refresh ti_includes.
  if not p_prog is initial.
    move: p_prog to ti_includes-nome,
          '0'    to ti_includes-nivel.
    append ti_includes.
  elseif not p_tcode is initial.
    select single pgmna
           from tstc
           into vl_pgmna
           where tcode eq p_tcode.
    if sy-subrc eq 0.
      move: vl_pgmna to ti_includes-nome,
             '0'     to ti_includes-nivel.
      append ti_includes.
    endif.
  endif.
 
endform." INICIALIZA_TABELA
'
*&---------------------------------------------------------------------*
*&      Form  CABECALHO
*&---------------------------------------------------------------------*
*       text
*----------------------------------------------------------------------*
*  -->  p1        text
*  <--  p2        text
*----------------------------------------------------------------------*
form cabecalho.
'
  data vl_complemento(50) type c.
 
  if p_tcode is initial.
    concatenate 'NO PROGRAMA' p_prog
           into vl_complemento
           separated by space.
  else.
    concatenate 'EN LA TRANSACCION' p_tcode
           into vl_complemento
           separated by space.
  endif.
 
  format color col_key.
  write: /001 sy-uline,
         /001 sy-vline,
          040 'RELACION DE USER-EXITS ENCONTRADAS', vl_complemento,
          140 sy-vline,
         /001 sy-uline.
  write: /001 sy-vline,
          003 'NOMBRE DEL PROGRAMA',
          044 sy-vline,
          046 'NIVEL',
          052 sy-vline,
          054 'LINEA',
          065 sy-vline,
          067 'TEXTO',
          140 sy-vline,
         /001 sy-uline.
 
endform." CABECALHO
'
*&---------------------------------------------------------------------*
*&      Form  USER_EXIT_NAO_ENCONTRADA
*&---------------------------------------------------------------------*
*       text
*----------------------------------------------------------------------*
*  -->  p1        text
*  <--  p2        text
*----------------------------------------------------------------------*
form user_exit_nao_encontrada.
  describe table ti_user_exit.
  check sy-tfill is initial.
  format color col_normal intensified on.
  write: /003 'NINGUNA USER-EXIT FUE LOCALIZADA!',
          139 '  '.
  format reset.
endform." USER_EXIT_NAO_ENCONTRADA
'
*&---------------------------------------------------------------------*
*&      Form  LISTA_USER_EXIT_ENCONTRADA
*&---------------------------------------------------------------------*
*       text
*----------------------------------------------------------------------*
*  -->  p1        text
*  <--  p2        text
*----------------------------------------------------------------------*
form lista_user_exit_encontrada.
'
  data vl_cor type c.
 
  loop at ti_user_exit.
 
    if vl_cor eq c_x.
      clear vl_cor.
    else.
      move c_x to vl_cor.
    endif.
 
*- AJUSTA COR NA TELA.
    if vl_cor eq c_x.
      format color col_normal intensified on.
    else.
      format color col_normal intensified off.
    endif.
 
*- INÍCIO DA IMPRESSÃO.
    write: /003 ti_user_exit-programa,
            046 ti_user_exit-nivel,
            054 ti_user_exit-linha,
            067 ti_user_exit-codigo_fonte,
            139 '  '.
  endloop.
endform." LISTA_USER_EXIT_ENCONTRADA
'
*&---------------------------------------------------------------------*
*&      Form  RODAPE
*&---------------------------------------------------------------------*
form rodape.
  describe table ti_includes.
  format color col_total.
  write: /001 sy-uline,
         /001 sy-vline,
          003 'TOTAL DE PROGRAMAS ANALIZADOS:', sy-tfill,
              '   -   NIVEL:', p_nivel,
          140 sy-vline,
         /001 sy-uline.
endform." RODAPE

Fuente
http://aprendeabap.com/documentos_ABAP/Z_VERIFICA_USER_EXIT.txt

Comentarios

Entradas más populares de este blog

A to Z of OLE Excel in ABAP 7.4

  SAP users, both business and end users always need to download the output of a report to spreadsheet and do their analytics.   The standard excel output from a report is very simple process but it is old fashioned and the spreadsheet looks quite boring.  There is no default formatting and the users have to do all the hard work of changing the fonts, coloring the texts, marking the borders etc. Updated 16th Aug 2019  –  If you are working in non-ABAP 7.4 (below), there is complete reference program for you too. Go to the end of this article.  Thank you  Legxis  ( LeonievonK ) for the share. I acknowledge, whatever I mentioned above can be achieved in many ways programmatically. We can do it in the old traditional ABAP way but  providing multiple tabs in the spreadsheet and formatting is quite tricky with non  OLE  method. OLE = Object Linking and Embedding The high level agenda of this article is to be the  G.O.A.T.  (please google it if you do not know the full form)  of OLE Excel Gu
How to add custom field in Additional B Tab for SAP Sales Order In this article we want to explain step by step how to add custom field in SAP Sales Order transaction VA01/VA02/VA03. This time Mr ABAPGurus will give the tutorial of enhancement to add custom field in SAP Sales order. In this sample we will add new custom field for comments and customer satisfaction, this data will save into separate table from SAP Standard table ( VBAK / VBAP ). SAP provided us with ADDITIONAL TAB in the sales order transaction ( VA01/VA02/VA03 ) which allow customer to add custom fields.  T he different between ADDITIONAL A and ADDITIONAL B is the ADDITIONAL A for field which already predefine in Sales Order Header ( VBAK ) fields and ADDITIONAL B is for field that freely define. This sample we will use ADDITIONAL B because we will store data from customer satisfaction into Z database table. 1. Create one Z table using SE11 SAP Transaction code. 2.Using SE38 Transaction code and ope

VOFM

Creating VOFM custom routine, functionality same as SAP standard routine 103 with Additional Functionality 1.    Introduction 1.1   Document Purpose 1.2    This is the document helps you to create custom routine for sales order for below specific requirement: Functional description: In case of sale order with the SD document category ‘K’ or ‘L’ or ‘H’ related to an invoice, we need to fill the fixed value date (VBKD_VALDT) with the billing reference date (VBRK_FKDAT). For example: Invoice 90001111, the billing date is 22.07.2013 If we create a sale order related to this invoice, we want the fixed value date equal to the billing reference date. As per the requirement: Sap standard routine ‘103’ triggers whenever sales order is being created with reference. Sap standard routine is configured in VOFM transaction as: Sap standard routine ‘103’ has the functionality of copying the billing document header data and billing document line item data into the