on 05-12-2006 4:57 AM
Hello guys,
I was trying some HTMLB examples. I got a portal runtime error
<b>Portal Runtime Error
An exception occurred while processing a request for :
iView : N/A
Component Name : N/A
Cannot find JSP file: button.jsp.
Exception id: 11:48_11/05/06_0013_4374750
See the details for the exception ID in the log file</b>
The log file shows that the jsp file is not been found.
In fact, I have the JSP file in my project, built the project, and uploaded to the portal. Where am I missing?
Thanks in advance.
Vicky
Hi vicky
Can you just post the code in your portalapp.xml file.
Have you added the component profile tag in that file.
Regards
Yoga
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Yoga, here is the xml file
<b><?xml version="1.0" encoding="utf-8"?>
<application>
<application-config>
<property name="PrivateSharingReference" value="com.sap.portal.htmlb"/>
</application-config>
<components>
<component name="ButtonExample">
<component-config>
<property name="ClassName" value="com.xyz.TestExample"/>
<property name="SecurityZone" value="com.uky.ButtonExample/high_safety"/>
<property name="ComponentType" value="jspnative"/>
<property name="JSP" value="pagelet/button.jsp"/>
</component-config>
<component-profile/>
</component>
</components>
<services/>
</application></b>
vicky
Hi vicky
Try this code and let me know the results.
<?xml version="1.0" encoding="utf-8"?>
<application>
<application-config>
<property name="SharingReference" value="com.sap.portal.htmlb"/>
</application-config>
<components>
<component name="ButtonExample">
<component-config>
<property name="ClassName" value="com.xyz.TestExample"/>
</component-config>
<component-profile>
<property name="tagLib" value="/SERVICE/htmlb/taglib/htmlb.tld"/>
</component-profile>
</component>
</components>
<services/>
</application>
Also, add the following code to the jsp file:
<%@ taglib uri="tagLib" prefix="hbj" %>
Regards
Yoga
Message was edited by: Yogalakshmi
Hi Vicky,
The problem is not with the button.jsp.
pls check the following...
1)Pls put the following xml tags under <components> tag
<components>
<component name="Button">
<component-config>
<property name="ClassName" value="<b>Vicky Your Dynpage Name</b>">
</property>
<property name="JSP" value="pagelet/button.jsp">
</property>
</component-config>
<component-profile>
<property name="tagLib" value="/SERVICE/htmlb/taglib/htmlb.tld">
</property>
</component-profile>
</component>
2) In ur dynpage the way u call ur jsp
from doProcessBeforeOutput() method of ur dynpage u should call the jsp as
this.setJspName("button.jsp");
3) The jsp file is kept under dist\PORTAL-INF\pagelet
regards,
Sujesh
Hi Vicky,
The problem is not with the button.jsp.
pls check the following...
1)Pls put the following xml tags under <components> tag
<components>
<component name="Button">
<component-config>
<property name="ClassName" value="<b>Vicky Your Dynpage Name</b>">
</property>
<property name="JSP" value="pagelet/button.jsp">
</property>
</component-config>
<component-profile>
<property name="tagLib" value="/SERVICE/htmlb/taglib/htmlb.tld">
</property>
</component-profile>
</component>
2) In ur dynpage the way u call ur jsp
from doProcessBeforeOutput() method of ur dynpage u should call the jsp as
this.setJspName("button.jsp");
3) The jsp file is kept under dist\PORTAL-INF\pagelet
regards,
Sujesh
Hi vicky.
Here is the source code.It worked fine for me.
Button.java
============
package com.button;
import com.sapportals.htmlb.event.Event;
import com.sapportals.htmlb.page.DynPage;
import com.sapportals.htmlb.page.PageException;
import com.sapportals.portal.htmlb.page.JSPDynPage;
import com.sapportals.portal.htmlb.page.PageProcessorComponent;
import com.sapportals.portal.prt.component.IPortalComponentResponse;
public class Button extends PageProcessorComponent {
public DynPage getPage(){
return new ButtonDynPage();
}
public static class ButtonDynPage extends JSPDynPage{
public void doInitialization(){
}
public void doProcessAfterInput() throws PageException {
}
public void doProcessBeforeOutput() throws PageException {
this.setJspName("button.jsp");
}
public void onSubmit(Event e)throws PageException {
IPortalComponentResponse resp = (IPortalComponentResponse)this.getResponse();
resp.write("button has been created successfully");
}
}
}
button.jsp
===========
<%@ taglib uri="tagLib" prefix="hbj" %>
<hbj:content id="myContext" >
<hbj:page title="PageTitle">
<hbj:form id="myFormId" >
<hbj:button
id="button"
text="Click"
width="125px"
tooltip="Click here"
onClick="onSubmit"
design="STANDARD"
/>
</hbj:form>
</hbj:page>
</hbj:content>
portalapp.xml
==============
<?xml version="1.0" encoding="utf-8"?>
<application>
<application-config>
<property name="SharingReference" value="com.sap.portal.htmlb"/>
</application-config>
<components>
<component name="Button">
<component-config>
<property name="ClassName" value="com.button.Button"/>
</component-config>
<component-profile>
<property name="tagLib" value="/SERVICE/htmlb/taglib/htmlb.tld"/>
</component-profile>
</component>
</components>
<services/>
</application>
Regards
Yoga
Hi Yoga, I am unfortunate that it is not working for me.
The same kind of error:
<b>Portal Runtime Error
An exception occurred while processing a request for :
iView : ButtonTest.Button
Component Name : ButtonTest.Button
Cannot find JSP file: button.jsp.
Exception id: 02:19_12/05/06_0027_4374750
See the details for the exception ID in the log file</b>
Moreover, you have included
<b><component-config>
<property name="ClassName" value="com.cts.form.form"/>
</component-config></b>
What is it all about ?
- Vicky
Hi Vicky,
in the project you sent to me there simply was no JSP inside the PAR - and the JSP within the project was at the wrong place (it was to be found under /private/pagelet but it must be /dist/PORTAL-INF/pagelet (as already mentioned before in this thread).
Whereas the entry <i><property name="JSP" value="pagelet/button.jsp"></property></i> which is mentioned in this thread is absolutely superflous, for this is a property only used for JSPNative components.
Hope it helps
Detlev
This has already been solved, but I had the same issue.
However, the JSP file was in the correct location.
The solution:
1. CLEAN the application from the portal (System administration --> Support --> portal Runtime --> "Portal Anywhere" Admin Tools --> Administration Console --> Archive Remover).
2. Upload the par file again.
That did the trick.
I just add this here, because I searched for the answer and this thread popped up. So other people who search for a solution for this issue can try this.
Cheers,
Edwin.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
86 | |
10 | |
10 | |
9 | |
6 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.