Skip to Content

Configuring the NW04s IDE to work with the PCD API

Configuring the NW04s IDE in order to work with the PCD API could be complicated at first, but with few easy steps this could be accomplished.

The process divides into two parts:

1. Defining the design time environment

2. Defining the runtime environment

This blog will instruct you throw this few steps that will enable you to code using the PCD API.


Step1 – Defining the design time environment

In order to code with the PCD API you need to use the API JARs.

In the NW04s environment in order to import external JARs you need to create an External Library Development Component.

/wp-content/uploads/2009/07/1_160543.png

Once you’ve created the DC, you need to add the wanted JARs to the DC.

The JAR files that you need to add are:

  • com.sap.portal.pcd.glservice_api.jar
  • gl_api.jar
  • tc~epbc~pcm~adminapi~java.jar
  • com.sap.security.api.jar

Adding the JARs is done by simply dragging them into the “libraries” folder of the DC form their filesystem location.

/wp-content/uploads/2009/07/2_1_160556.png

Every JAR that you’ve added to the DC is needs to be added to the DC public part.
This is done by right clicking on the JAR in the “libraries” folder, and selecting “Development Component“->”Add to public part“.

/wp-content/uploads/2009/07/3_1_160557.png

Once you’ve done adding all the JARs to the public part, you can view it in the DC perspective.

/wp-content/uploads/2009/07/5_1_160558.png

Build the DC to complete this step.       

Adding the External JARs DC to the WebDynpro DC

Now you need to add the External Library DC that you’ve created to your WebDynpro DC.

In the WebDynpro Explorer, browse to your project to “DC Metadata”->“DC Definition”->“Used DCs”.

Right click on the “Used DCs” folder and select “Add Used DC…

/wp-content/uploads/2009/07/6_160562.png

Add the External Library DC that you’ve created and apply it for Build time.

/wp-content/uploads/2009/07/9_160563.png

Rebuild the WebDynpro DC, and you are all set!

Now you can code in WebDynpro and use the PCD API.

Step 2 – Defining the runtime environment

So now you can code with the PCD API, but you need to define to the WebDynpro DC which references the application is going to need to use in the runtime server.

In order to do that you need to go to the Development Component properties, and browse to “Web Dynpro References“, and select the “Sharing References” tab.

You need to add the following references:

  • PORTAL:sap.com/com.sap.portal.pcd.glservice
  • PORTAL:sap.com/com.sap.portal.pcm.admin.apiservice
  • PORTAL:sap.com/com.sap.portal.pcd.basicrolefactory

/wp-content/uploads/2009/07/8_160564.png

Apply the changes, and rebuild the DC.

That’s it! Now you’ve configured you WebDynpro DC to use the PCD API and you are ready to code 🙂

If you want to read some more about using the PCD API, check out the following documents:

Happy coding,

Doron.

To report this post you need to login first.

2 Comments

You must be Logged on to comment or reply to a post.

Leave a Reply