Reusing attachment wrapper component FPM_ATTACHMENT_WRAPPER in FPM

Sometimes application needs to upload some kinds of document( attachment ) from the user desktop and store in sap data base or in content server.

The below post shows how we can reuse the FPM_ATTACHMENT_WRAPPER component to upload any document. Once we receive the source place i.e URl then the document content can be uploaded by the standard frontend service methods or GUI_UPLOAD FM technique and then it can be stored any where as desired.

FPM_ATTACHMENT_WRAPPER  component provides either ECM ( Enterprise Content Management ) or KPro( knowledge Provider ) storage types to store the document  but the post doesn’t speak in detail about the storage types but just tells how FPM_ATTACHMENT_WRAPPER component can be sued to just reuse the ATTACHMENT WINDOW. Currently FPM_ATTACHMENT_WRAPPER provided in the list uibbs.

On the list uibb we have a button called Attachment.

1

When user clicks on the attachment button a upload browsing pop up appears by FPM_ATTACHMENT_WRAPPER component.

2

User can browse and select a doc and provide a document name and on click ok the document content can be uploaded and stored as per required.

34

The feeder class for the list uibb.

567

Create an event for the button.

89

Create an ovp application configuration.

10

 

Select free style uibb  and provide component name as FPM_ATTACHMENT_WRAPPER and create a configuration.

11

Create a list uibb configuration.

12

Here the storage type as ECM – Enterprise Content Management or KPro- Knowledge Provider.

13

List UIBB configuration.

1415

In the process event of the feeder class the below logic should be added to open the attachment upload pop up.

16

17

Test the application and on click on the button the pop up appears.

18

Put some code to handle the OK button from the pop up.

19

Now when the ok button is selected we should be able to read the document content from the address. So put the below code.

2021

When OK button is pressed . The event parameter gives the details.

222324

So here we have the file name URL and then by the forntend service method call we can read/upload the content and stores in ECM or Kpro.

25


 

Advertisements

3 comments

  1. Hi Shiv,

    Good and nice example for FPM attachment!

    Appreciate you can share with me how to setup the content server for Kpro or Ecm for FPM Reusing attachment wrapper component FPM_ATTACHMENT_WRAPPER.

    Beside that, I have error message(Error when uploading; the file name is invalid or the file is too large
    ) when I try to upload the attachment via the standard component.
    Below is the SAP note that I had implemented as per all the people have be given in scn. But it still didnt work.
    1736212
    1707551
    1710197
    1712530
    1722226
    1725479
    1731880
    1731881
    1737427
    1741713
    1743256
    1743257
    1747016
    1747018
    1752676
    1752677
    1731985
    1784975
    1791729

    My SAP system is Netweaver ECC 7.31SP04.

    Thanks.

    Regards,
    Gim Han Fu

    Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s