cancel
Showing results for 
Search instead for 
Did you mean: 

Creating a collaboration service.

SRudra
Contributor
0 Kudos

Hi,

I am using this tutorial at

http://help.sap.com/saphelp_nw04s/helpdata/en/9e/849b42641a0731e10000000a1550b0/frameset.htm

I have added a few lines of more code to iterate the arraylist and display the values.The full listing of my code goes as :

package com.rh.sukanta.demo.kmc.collaboration;

import java.util.ArrayList;

import java.lang.Exception;

import com.sap.netweaver.kmc.people.shared.ctx.ContextContainer;

import com.sapportals.htmlb.Form;

import com.sapportals.htmlb.page.DynPage;

import com.sapportals.htmlb.page.PageException;

import com.sapportals.htmlb.rendering.IPageContext;

import com.sapportals.portal.htmlb.page.PageProcessorComponent;

import com.sapportals.portal.prt.component.IPortalComponentRequest;

import com.sapportals.portal.prt.component.IPortalComponentResponse;

public class SimpleCollaborationService2 extends PageProcessorComponent {

public DynPage getPage() {

return new SimpleCollaborationService2DynPage();

}

public static class SimpleCollaborationService2DynPage extends DynPage {

/**

  • Initialization code executed once per user.

*/

public void doInitialization() throws PageException {

}

/**

  • Input handling code. In general called the first time with the second page request from the user.

*/

public void doProcessAfterInput() throws PageException {

}

/**

  • Create output. Called once per request.

*/

public void doProcessBeforeOutput() throws PageException {

Form myForm = this.getForm(); // get the form from DynPage

// create your GUI here....

IPageContext pc = getPageContext();

IPortalComponentRequest request = (IPortalComponentRequest)pc.getRequest();

// Use the PortalComponentRequest to create the ContextContainer

ContextContainer container = new ContextContainer(request);

try{

// Retrieve flat list of UniqueIds of Principals

ArrayList peopleIdList = container.getResolvedPeopleList();

// put your application logic here ...

IPortalComponentResponse response = (IPortalComponentResponse)pc.getResponse();

for(int i=0; i<peopleIdList.size();i++)

{

response.write(peopleIdList.get(i).toString());

}

}

catch(Exception e){

throw new PageException(e);

}

}

}

}

Now I have compiled the and deployed the .par file sucessfully on the server. How do I execute the example post deployment of the .PAR file. Plz let me know the step by step method to execute the example.

warm regds,

Sukanta Rudra

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

hi sukanta,

Create an iview from you par file in PCD and preview the iview.

see this link for more info on creating an iview.

http://help.sap.com/saphelp_nw70/helpdata/en/f5/eb50360e6a11d7b84900047582c9f7/frameset.htm

rgds,

Siva

Answers (0)