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

Creating attachments/Hyperlink in the transaction

Former Member
0 Likes
667

Hello,

I am having a requirment where-in I wanted to attach some files to the standard PS transaction. Any idea how this can be achieved. I know we can attach files to the accounting documents.

can we persists such objects into SAP transparent table? the another alternative to this may be to store a hyperlink (these documents are at the HTTP location) but can we open the hyperlink from any of the text field of sap?

thanks in advance.

regards

rajeev

1 ACCEPTED SOLUTION
Read only

RaymondGiuseppi
Active Contributor
0 Likes
627

Do some search at SDN on [GOS|https://www.sdn.sap.com/irj/scn/advancedsearch?query=gos&cat=sdn_all] (General Object Services)

A good start would be [How to Attach Documents to Any Custom Program Using Generic Object Services|https://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/0e6b0d95-0a01-0010-4696-ca0a48de5fb3]

Regards,

Raymond

Hello,

I am having a requirment where-in I wanted to attach some files to the standard PS transaction. Any idea how this can be achieved. I know we can attach files to the accounting documents.

can we persists such objects into SAP transparent table? the another alternative to this may be to store a hyperlink (these documents are at the HTTP location) but can we open the hyperlink from any of the text field of sap?

thanks in advance.

regards

rajeev

3 REPLIES 3
Read only

Former Member
0 Likes
627

Hi,

You can use the following Function Module to attach the hyperlink.

*&---------------------------------------------------------------------*
*&      Module  USER_COMMAND_0002  INPUT
*&---------------------------------------------------------------------*
*       text
*----------------------------------------------------------------------*
data: l_fieldname   type scrfname.

MODULE USER_COMMAND_0002 INPUT.

CASE SY-UCOMM.

 WHEN 'PICK'.
 get cursor field l_fieldname.
    if l_fieldname eq 'T1'.
      call function 'CALL_BROWSER'
           exporting   url    = 'http://www.yahoo.com/'
           exceptions others  = 1.
    Endif.

ENDCASE.

ENDMODULE.                 " USER_COMMAND_0002  INPUT
*&---------------------------------------------------------------------*
*&      Module  STATUS_0002  OUTPUT
*&---------------------------------------------------------------------*
*       text
*----------------------------------------------------------------------*
DATA: T1(50) TYPE C.

MODULE STATUS_0002 OUTPUT.
  SET PF-STATUS 'MAIN'.
*  SET TITLEBAR 'xxx'.

  T1 = 'Yahoo Homepage'.                      u201CT1 is name of I/O box

ENDMODULE.                 " STATUS_0002  OUTPUT

Regards,

Nikhil.

Read only

RaymondGiuseppi
Active Contributor
0 Likes
628

Do some search at SDN on [GOS|https://www.sdn.sap.com/irj/scn/advancedsearch?query=gos&cat=sdn_all] (General Object Services)

A good start would be [How to Attach Documents to Any Custom Program Using Generic Object Services|https://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/0e6b0d95-0a01-0010-4696-ca0a48de5fb3]

Regards,

Raymond

Read only

Former Member
0 Likes
627

Will try with open browser option