cancel
Showing results for 
Search instead for 
Did you mean: 

Adding text in FBL5n

Former Member
0 Kudos

Hello experts,

Please resolve my Problem.

Actually There is a requirement from user, In FBL5N if Doc type is RV, Test Column is Printing Nothing, It is coming Blank.

Now user wants to Display data there from VA01 tcode, there he is adding text in GO->header->texts.

Please guide me is it possible to dispay text in standard report FBL5n in case of RV DOc type from va01 or va02.

Should i use some exit or i have to make its z report for changings.

Waiting For a positive Reply

Regards

Shelly Malik

Accepted Solutions (1)

Accepted Solutions (1)

former_member673464
Active Contributor
0 Kudos

hi,

We have substitutions for filling the text for finance documents based on document types. You can maintain those substitutions in transaction GGb1. You cannot change the old ones but if you want you can write code for the new documents after the substitution is implemented.

regards,

Veeresh

Former Member
0 Kudos

Hello thanks For ur Reply,

Can you please guide me in which substitution i should add code for adding text in FBL5N, As there are lots of Substitution and Please give me some Exmples of how to use GGB1 tcode.

Regards

Shelly Malik

brad_bohn
Active Contributor
0 Kudos

Though Raymond's note is an option, I don't think you need an additional field. It sounds like you are merely trying to transfer the contents of a sales order long text to the A/R line item text line (BSEG-SGTXT) so that it will display in FBL5N. I certainly WOULD NOT create an implicit enhancement or copy FBL5N - that's a hack's solution. A substituiton exit will certainly work as well but it's somewhat of an 'after-the-fact' approach. There are user exits available to influence the transfer of fields from SD to A/R if this is what you need.

Text Determination configuration identifies whether texts copy from the reference document. You can pass the A/R text from the sales order to the billing document. This keeps the information available in each document. Then, you can use enhancement SDVFX008, component EXIT_SAPLV60B_008 to read the text during the transfer to A/R and assign the text to SGTXT field on the relevant line items in XACCIT.

Former Member
0 Kudos

Hello Brad,

Thanks for your Answer,

But i am Little Bit Confused, U told me to use SDVFX008 User Exit, For adding Text, I just Want to know is this Exit Will Add text in somwhere in standard table or will Display text in FBL5N Report which i want to pick up From VA02 tcode From Header Text, Please Clarify me as how i can use this Exit, As i Used Break Point Inside this Exit And Activate, When i run FBL5N Report cursor is not triggering there, So i am Unable to understand where or in Which Tcode this Exit is Triggering.

Please Reply BAck....

Regards

Shelly Malik

raymond_giuseppi
Active Contributor
0 Kudos

My answer is triggered in FBL5N, most other answers change the FI document text when creating from SD (SD user-exit or FI Substitution during posting)

Regards,

Raymond

Former Member
0 Kudos

Thanks Sir,

Can you Explain me More as i am Unable to open any SAP note Rocommended by you in Last Reply. I just Want to display Text in FBL5N Report in case of RV Doc, Which user will add in VF02->go->Header->text.

Right now i have made z report of FBL5N,And Addd Follwing code For Dispaying Text

data: tline like tline OCCURS 0 WITH HEADER LINE.
  data: name like THEAD-TDNAME.
  data: tabix like sy-tabix.

* Get Text only in case of RV
  loop at it_pos.
    tabix = sy-tabix.
    if it_pos-blart = 'RV'.
      clear: tline, tline[].
      name = it_pos-belnr.
      CALL FUNCTION 'READ_TEXT'
        EXPORTING
          CLIENT   = SY-MANDT
          ID       = '0002'
          LANGUAGE = 'E'
          NAME     = name
          OBJECT   = 'VBBK'
        TABLES
          LINES    = tline.
      IF SY-SUBRC <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
*         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      else.
        READ TABLE tline INDEX 1.
        it_pos-sgtxt = tline-tdline.
        modify it_pos index tabix.
      ENDIF.
    endif.
  endloop.

But i want to Display text in Standard in FBL5N Only During Execution Of Report

Please help me.

Regards

Shelly Malik.

raymond_giuseppi
Active Contributor
0 Kudos

Roadmap

- First take a look at BTE 00001650 (use transaction FINF), read documentation, look at sample FM.

- Copy the sample FM provided, SAMPLE_INTERFACE_00001650, to a Z_FM.

- Put your code (READ_TEXT => SGTXT) in this new FM.

- Activate FM (and FG).

- Call transaction FIBF , in Menu : Settings, Products, of a customer (or transaction BF24), If there is no active product already created and acticated, create a Product code and check the active box.

- Call transaction FIBF, in Menu : Settings, P/S function modules, of a customer (or transaction BF34), add your FM with event 00001650 and your product code

- Call transaction FBL5N to test

Some remarks

- The OSS notes were useful if you wanted to add a new text field, and not change the item text.

- Optimize your FM , it will be called on an item per item basis, so bufferize as soon as possible

- Check invoice/FI document relation (NAME = RFPOS-VBELN and not RFPOS-BELNR, also, there may be many header texts on an invoice)

Regards,

Raymond

Former Member
0 Kudos

Hello Sir,

Thank you So Much sir. I added given below code in my z function, During FBL5N it is triggering here but Sir In Output it is displaying only empty Lines, It is not Displaying any data. Can you Please tell me where is the Exact Problem.

if I_POSTAB-blart = 'RV'.
    name = I_POSTAB-belnr.
    CALL FUNCTION 'READ_TEXT'
      EXPORTING
       CLIENT                        = SY-MANDT
        ID                           = '0002'
        LANGUAGE                     = 'E'
        NAME                          = name
        OBJECT                        = 'VBBK'
*   ARCHIVE_HANDLE                = 0
*   LOCAL_CAT                     = ' '
* IMPORTING
*   HEADER                        =
      TABLES
        LINES                         = Tline
 EXCEPTIONS
   ID                            = 1
   LANGUAGE                      = 2
   NAME                          = 3
   NOT_FOUND                     = 4
   OBJECT                        = 5
   REFERENCE_CHECK               = 6
   WRONG_ACCESS_TO_ARCHIVE       = 7
   OTHERS                        = 8
              .
    IF SY-SUBRC <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
*         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.

    else.
      READ TABLE tline INDEX 1.
      I_POSTAB-sgtxt = tline-tdline.
    ENDIF.
  ENDIF.

Former Member
0 Kudos

thanku So much Sir,

Finally I got the Reason,

Now it is working OK.

sir now i only have one Querry Before transportation to online server i just want to know will it effect on Some other Place, Or will Work only For FBL5N.

Please Sir I am Waiting for a positive Reply from ur side.

Thanks

Shelly Malik

raymond_giuseppi
Active Contributor
0 Kudos

That will work on many standard FI reports like the other FBL*n transactions, and reports that use the standard RFPOS structure to display FI document via standard FM like FI_ITEMS_DISPLAY.

Of course, if you want to restrict the execution, just add a check on current transaction code (CHECK SY-TCODE = 'FBL5N' immediately after the copy of import to export parameter, before changing/adding any value.)

Regards,

Raymond

Answers (4)

Answers (4)

Former Member
0 Kudos

Thanks

Former Member
0 Kudos

Still Waiting For A Reply From Mr. Raymond

raymond_giuseppi
Active Contributor
0 Kudos

Lunch time

Look at FM parameter

- Your FM should begin with a E_POSTAB = I_POSTAB, else you get initial lines...

- Then put the result in E_POSTAB-SGTXT (exported parameter)

Regards,

Raymond

0 Kudos

Hello Raymont,

I have same issue and i desperate need your help,

I am familiar with BTE but unfortunately not with abap code and that's where i need your help.

My requirement is exactly same thing but for two document types (DO and DF) and to work just for one company code (HR01).

please make necessary changes to my code.

E_POSTAB = I_POSTAB.

IF I_POSTAB-blart = 'DO'.

    NAME = I_POSTAB-VBELN.

CALL FUNCTION 'READ_TEXT'

  EXPORTING

  CLIENT = SY-MANDT

  ID = '0002'

  LANGUAGE = 'HR'

  NAME = NAME

  OBJECT = 'VBBK'

* ARCHIVE_HANDLE = 0

* LOCAL_CAT = ' '

* IMPORTING

* HEADER =

  TABLES

  LINES = it_lines

  EXCEPTIONS

  ID = 1

  LANGUAGE = 2

  NAME = 3

  NOT_FOUND = 4

  OBJECT = 5

  REFERENCE_CHECK = 6

  WRONG_ACCESS_TO_ARCHIVE = 7

  OTHERS = 8

  IF SY-SUBRC <> 0.

* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO

* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.

  ELSE.

  ..........................

raymond_giuseppi
Active Contributor
0 Kudos

There is a business event to add information when displaying FI document ([BTE 00001650|http://forums.sdn.sap.com/search.jspa?threadID=&q=00001650+BTE&objID=c42&dateRange=all&numResults=15&rankBy=10001])

First read OSS [Note 984305 - Line item: Definition of special fields (T021S)|https://service.sap.com/sap/support/notes/984305] which explains the procedure (Customizing and development), then specifically for a long text, read OSS [Note 368310 - LI: Open FI: long text for special G/L transacs|https://service.sap.com/sap/support/notes/368310]

Regards,

Raymond

venkatesan_nagiah
Active Participant
0 Kudos

you can try by implementing implicit enhancement

otherwise, you need to copy the report and make custom one. because it reads from only fi document tables.

venkat