Use BC4J inside servlets

Hi,
This may be a dumb question but I'm new to JDeveloper. I created my Business Components and can use it inseide applets and JSP's - but ich couldnt find a way to use it (via wizzard) inside a servlet. Could anybody give me a tip
TIA
Oliver
null

<BLOCKQUOTE><font size="1" face="Verdana, Arial">quote:</font><HR>Originally posted by David Roberts ([email protected]):
I would like to use the functionality of bc4j data tags inside servlets.
My aim is to do code intensive operations inside a servlet and forward the results, if necessary, to a JSP page.
The most convenient way of accessing data in BC4J are the JSP data tags. I was wondering if there is a way of instantiating them as normal Java Classes in a servlet, and using class methods to perform the database update operations that I want?<HR></BLOCKQUOTE>
null

Similar Messages

  • Java.lang.NoSuchMethodError: getSocket using JavaMail inside JBoss

    Hi,
    i built a library to easily send emails with JavaMail, via SMTP. When i use my lib in a stand-alone java application, it works fine, but when i need to use it inside my web application, deployed on JBoss AS, i get the following error:
    Servlet.service() for servlet action threw exception
    java.lang.NoSuchMethodError: getSocket
         at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:1250)
         at com.sun.mail.smtp.SMTPTransport.protocolConnect(SMTPTransport.java:370)
         at javax.mail.Service.connect(Service.java:233)
         at it.compit.mail.helper.send.SMTPSender.send(SMTPSender.java:39) where it.compit.mail.helper.send.SMTPSender.send is the method i use to send email in my lib. SMTPSender.java at line 39 is
    SMTPTransport tr = (SMTPTransport) session.getTransport("smtp"); I don't want to use SessionBean to send email from JBoss AS. I did not include mail.jar in server/default/lib dir because JBoss has got a built-in implementation of JavaMail. Using javamail debugging, i've noticed that javamail inside my JBoss is "JavaMail version 1.3.1", while i used version 1.4ea to build my lib.
    So, any ideas to solve my problem?
    Thanks in advance.
    Elisa Distefano a.k.a Etha

    Hi bshannon,
    i looked for other javamail libs in my JBoss dir: found nothing but the only mail.jar located in server/default/lib/ (provided by default installation). I tried to specify the classpath into mail-service.xml without success.
    I also noticed that when JBoss starts, logs print "DEBUG: JavaMail version 1.3.1 " while the MANIFEST.MF inside my mail.jar contains "Implementation-Version: 1.4".
    My JBoss version is 4.0.4 GA. Any idea?!?

  • Npe when using popup inside adf table column

    hi i have a popup witch is inside adf column table but when i click the button i get this npe error
    <af:column id="c7" headerText="Action">
                  <af:commandButton text="Add" id="cb2">
                    <af:showPopupBehavior popupId="p1" triggerType="click"/>
                  </af:commandButton>
                  <af:panelGroupLayout id="pgl2" inlineStyle="width:1042px;"
                                       layout="horizontal" valign="middle"
                                       halign="right">
                    <af:popup id="p1" contentDelivery="lazyUncached">
                      <af:dialog id="d1" type="cancel">
                        <af:region value="#{bindings.usrtaskflowdefinition1.regionModel}"
                                   id="r1"/>
                      </af:dialog>
                    </af:popup>
                    <af:commandButton text="Cancel" id="cb1" rendered="false"/>
                    <af:commandButton text="Remove" id="cb3" visible="false"/>
                  </af:panelGroupLayout>
                </af:column>
    am geting this NPE ERROR
    <FacesCtrlSearchBinding> <release> ADFv: release():: Release all resources.
    <ADFLogger> <end> ADF web request
    <XmlErrorHandler> <handleError> ADF_FACES-60096:Server Exception during PPR, #1
    javax.el.ELException: java.lang.NullPointerException
        at javax.el.BeanELResolver.getValue(BeanELResolver.java:266)
        at com.sun.faces.el.DemuxCompositeELResolver._getValue(DemuxCompositeELResolver.java:173)
        at com.sun.faces.el.DemuxCompositeELResolver.getValue(DemuxCompositeELResolver.java:200)
        at com.sun.el.parser.AstValue.getValue(Unknown Source)
        at com.sun.el.parser.AstEqual.getValue(Unknown Source)
        at com.sun.el.parser.AstOr.getValue(Unknown Source)
        at com.sun.el.ValueExpressionImpl.getValue(Unknown Source)
        at org.apache.myfaces.trinidad.bean.FacesBeanImpl.getProperty(FacesBeanImpl.java:68)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.getBooleanProperty(UIXComponentBase.java:1204)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.isRendered(UIXComponentBase.java:423)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.processValidators(UIXComponentBase.java:810)
        at org.apache.myfaces.trinidad.component.UIXEditableValue.processValidators(UIXEditableValue.java:263)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.validateChildrenImpl(UIXComponentBase.java:1022)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.validateChildren(UIXComponentBase.java:1007)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.processValidators(UIXComponentBase.java:814)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.validateChildrenImpl(UIXComponentBase.java:1022)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.validateChildren(UIXComponentBase.java:1007)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.processValidators(UIXComponentBase.java:814)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.validateChildrenImpl(UIXComponentBase.java:1022)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.validateChildren(UIXComponentBase.java:1007)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.processValidators(UIXComponentBase.java:814)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.validateChildrenImpl(UIXComponentBase.java:1022)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.validateChildren(UIXComponentBase.java:1007)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.processValidators(UIXComponentBase.java:814)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.validateChildrenImpl(UIXComponentBase.java:1022)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.validateChildren(UIXComponentBase.java:1007)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.processValidators(UIXComponentBase.java:814)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.validateChildrenImpl(UIXComponentBase.java:1022)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.validateChildren(UIXComponentBase.java:1007)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.processValidators(UIXComponentBase.java:814)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.validateChildrenImpl(UIXComponentBase.java:1022)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.validateChildren(UIXComponentBase.java:1007)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.processValidators(UIXComponentBase.java:814)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.validateChildrenImpl(UIXComponentBase.java:1022)
        at oracle.adf.view.rich.component.fragment.UIXRegion.validateChildrenImpl(UIXRegion.java:634)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.validateChildren(UIXComponentBase.java:1007)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.processValidators(UIXComponentBase.java:814)
        at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl$ProcessValidationsCallback.invokeContextCallback(LifecycleImpl.java:1422)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.invokeOnNamingContainerComponent(UIXComponentBase.java:1358)
        at oracle.adf.view.rich.component.fragment.UIXRegion.invokeOnComponent(UIXRegion.java:555)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.invokeOnChildrenComponents(UIXComponentBase.java:1330)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.invokeOnComponent(UIXComponentBase.java:1424)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.invokeOnChildrenComponents(UIXComponentBase.java:1330)
        at org.apache.myfaces.trinidad.component.UIXComponentBase.invokeOnComponent(UIXComponentBase.java:1424)
        at oracle.adf.view.rich.component.rich.RichDocument.invokeOnComponent(RichDocument.java:168)
        at javax.faces.component.UIComponent.invokeOnComponent(UIComponent.java:720)
        at javax.faces.component.UIComponentBase.invokeOnComponent(UIComponentBase.java:678)
        at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._executePhase(LifecycleImpl.java:407)
        at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:194)
        at javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
        at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
        at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
        at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:300)
        at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)
        at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
        at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:205)
        at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
        at oracle.adfinternal.view.faces.webapp.rich.RegistrationFilter.doFilter(RegistrationFilter.java:106)
        at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:446)
        at oracle.adfinternal.view.faces.activedata.AdsFilter.doFilter(AdsFilter.java:60)
        at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:446)
        at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl._doFilterImpl(TrinidadFilterImpl.java:271)
        at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl.doFilter(TrinidadFilterImpl.java:177)
        at org.apache.myfaces.trinidad.webapp.TrinidadFilter.doFilter(TrinidadFilter.java:92)
        at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
        at oracle.adf.library.webapp.LibraryFilter.doFilter(LibraryFilter.java:179)
        at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
        at oracle.security.jps.ee.http.JpsAbsFilter$1.run(JpsAbsFilter.java:119)
        at java.security.AccessController.doPrivileged(Native Method)
        at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:315)
        at oracle.security.jps.ee.util.JpsPlatformUtil.runJaasMode(JpsPlatformUtil.java:442)
        at oracle.security.jps.ee.http.JpsAbsFilter.runJaasMode(JpsAbsFilter.java:103)
        at oracle.security.jps.ee.http.JpsAbsFilter.doFilter(JpsAbsFilter.java:171)
        at oracle.security.jps.ee.http.JpsFilter.doFilter(JpsFilter.java:71)
        at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
        at oracle.dms.servlet.DMSServletFilter.doFilter(DMSServletFilter.java:139)
        at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
        at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:27)
        at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
        at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.wrapRun(WebAppServletContext.java:3715)
        at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3681)
        at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
        at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
        at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2277)
        at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2183)
        at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1454)
        at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
        at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)
    Caused by: java.lang.NullPointerException
        at oracle.adf.model.binding.DCControlBinding.reportException(DCControlBinding.java:201)
        at oracle.jbo.uicli.binding.JUCtrlValueBinding.findAttributeDef(JUCtrlValueBinding.java:632)
        at oracle.jbo.uicli.binding.JUCtrlValueBinding.findAttributeDef(JUCtrlValueBinding.java:597)
        at oracle.jbo.uicli.binding.JUCtrlValueBinding.getAttribute(JUCtrlValueBinding.java:1341)
        at oracle.adfinternal.view.faces.model.binding.FacesCtrlSearchBinding$AdfAttributeCriterion.getOperator(FacesCtrlSearchBinding.java:2240)
        at sun.reflect.GeneratedMethodAccessor357.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at javax.el.BeanELResolver.getValue(BeanELResolver.java:261)
        ... 87 more
    <QueryCollection> <finalize> [4342] ##### QueryCollection.finl no RowFilter
    <QueryCollection> <finalize> [4343] ##### QueryCollection.finl oracle.jbo.Key[Surname 0 0 ]
    <QueryCollection> <finalize> [4344] ##### QueryCollection.finl oracle.jbo.Key[Firstname 0 0 ]
    <ControllerState> <finalizeRequest> ADFc: Request number [9] for session [14gycvxp1h_] has been finalized.
    <QueryCollection> <finalize> [4345] ##### QueryCollection.finl oracle.jbo.Key[Username 0 0 ]
    <RootViewPortContextImpl> <unlockViewPortRequestLock> ADFc: Attempting to release RootViewPort request lock on 14gycvxp1h_0
    <QueryCollection> <finalize> [4346] ##### QueryCollection.finl oracle.jbo.Key[Organisationname 0 0 ]
    <QueryCollection> <finalize> [4347] ##### QueryCollection.finl oracle.jbo.Key[Surname 0 0 ]
    <RootViewPortContextImpl> <unlockViewPortRequestLock> ADFc: Successfully released RootViewPort request lock on 14gycvxp1h_0
    <QueryCollection> <finalize> [4348] ##### QueryCollection.finl oracle.jbo.Key[Firstname 0 0 ]
    <QueryCollection> <finalize> [4349] ##### QueryCollection.finl oracle.jbo.Key[Username 0 0 ]
    <Auditor> <isEnabled> IAU:Event Enabled : false, Event Type : CheckPermission, Event Status : true, Properties : null
    <QueryCollection> <finalize> [4350] ##### QueryCollection.finl oracle.jbo.Key[Organisationname 0 0 ]
    <QueryCollection> <finalize> [4351] ##### QueryCollection.finl no RowFilter
    <QueryCollection> <finalize> [4352] ##### QueryCollection.finl no RowFilter
    <Auditor> <isEnabled> IAU:Event Enabled : false, Event Type : CheckPermission, Event Status : true, Properties : null
    <QueryCollection> <finalize> [4353] ##### QueryCollection.finl no RowFilter
    <QueryCollection> <finalize> [4354] ##### QueryCollection.finl no RowFilter
    <QueryCollection> <finalize> [4355] ##### QueryCollection.finl no RowFilter
    <QueryCollection> <finalize> [4356] ##### QueryCollection.finl no RowFilter
    <QueryCollection> <finalize> [4357] ##### QueryCollection.finl no RowFilter
    <QueryCollection> <finalize> [4358] ##### QueryCollection.finl no RowFilter
    <QueryCollection> <finalize> [4359] ##### QueryCollection.finl no RowFilter
    <QueryCollection> <finalize> [4360] ##### QueryCollection.finl no RowFilter
    <QueryCollection> <finalize> [4361] ##### QueryCollection.finl no RowFilter
    <QueryCollection> <finalize> [4362] ##### QueryCollection.finl no RowFilter
    <QueryCollection> <finalize> [4363] ##### QueryCollection.finl no RowFilter
    <QueryCollection> <finalize> [4364] ##### QueryCollection.finl no RowFilter
    <AbstractExecutionContext> <getECForJDBC> adding new ECForJDBC null to set of listeners for this context
    <WatchingDocumentChangeNotifier> <run> decide if checkUsingListeners should run. loopCnt: 0 changeInterval: 60000 originalChangeInterval: 60000 forceCheckForUpdate: false notifier instance: oracle.as.config.notification.filesystem.WatchingDocumentChangeNotifier@ca7192
    <WatchingDocumentChangeNotifier> <checkUsingListeners> BEGIN checkUsingListeners for notifier instance: oracle.as.config.notification.filesystem.WatchingDocumentChangeNotifier@ca7192
    <WatchingDocumentChangeNotifier> <checkUsingListeners> notifier processing file: C:\Users\10017134\App

    Caused by: java.lang.NullPointerException
        at oracle.adf.model.binding.DCControlBinding.reportException(DCControlBinding.java:201)
        at oracle.jbo.uicli.binding.JUCtrlValueBinding.findAttributeDef(JUCtrlValueBinding.java:632)
        at oracle.jbo.uicli.binding.JUCtrlValueBinding.findAttributeDef(JUCtrlValueBinding.java:597)
        at oracle.jbo.uicli.binding.JUCtrlValueBinding.getAttribute(JUCtrlValueBinding.java:1341)
        at oracle.adfinternal.view.faces.model.binding.FacesCtrlSearchBinding$AdfAttributeCriterion.getOperator(FacesCtrlSearchBinding.java:2240)
    It seems that problem is caused by af:query or quickquery component(or underlying view object or view criteria).
    Maybe you can drop BTF as static region directly to your page and see if this will run correctly?
    YES i have try stll does not work
    So then this is not related with "npe when using popup inside adf table column"  
    Dario

  • Using bc4j with applets

    Hi,
    I was wondering if you have any tips on using bc4j in applets. The 2 biggest problems I'm having is the jar size of the applet after all libs are included
    (4MB+) and the fact that I can't use XDK, JNDI, BC4J and some other libs from applets unless I sign them or change the policy file at each client using the applets.
    I really think all the calls to System.getProperties(), etc. should be placed inside try catch blocks to catch the security exceptions raised by xdk, RMIInitialContextFactory, etc. and handled using
    defaults for properties... it'd be even better if these properties could be set in another way as well.
    Thanks in advance,
    Leonardo Bueno

    FYI... my environment is:
    Oracle9iAS (9.0.3.0.0)
    JDeveloper (9.0.3.4)

  • Urgent Pls - Using BC4J Intermedia tags

    Hi,
    I am using BC4J Intermedia tag EmbedImage to display images stored in Databases. When I try to display I get only a blank picture equivalent to the size of the image and not the image itself. The type of the image is JPG. The Image datatype in the database is ORDSYS.ORDIMAGE.
    Is it to do something with the project settings? I am using Oracle 9.0.3 version of JDeveloper.
    Any help is appreciated.
    Thanks
    Priya

    Right, that's because the oracle.ord.html.URLBuilder class builds the URL for the images by using the current JSP directory level.
    For example: if your JSP page that uses <jbo:EmbedImage> is located under http://hostname.com/contextRoot/mydir/. Then the generated URL for the image will be http://hostname.com/contextRoot/mydir/ordDeliverMedia?....
    But in web.xml, the <url-pattern> element defines the url pattern value, which by default is "/ordDeliverMedia". So the media delivery servlet only handles the requests like these: http://hostname.com/contextRoot/ordDeliverMedia?...
    So, in order to make your sample work, you need to modify the web.xml in your project. There are two alternatives:
    1. Change the <url-pattern> element to this:
    <url-pattern>/kerfisumsjon/ordDeliverMedia</url-pattern>
    This will correctly handle the JSPs located under kerfisumsjon.
    Or
    2. Change the <url-pattern> element to this:
    <url-pattern>*ordDeliverMedia</url-pattern>
    This will handle any requests for ordDeliverMedia regardless of their directory location.
    Hope this solves your problem.
    Richard

  • Using bc4j jbo tags

    Hot to get the id of a topic added in previous jsp page using bc4j jbo tags

    Do you want to use the value in a Java variable? If so then here's what you do:
    1) Inside your rowset iterate tag, use the <jbo:Row> tag and set action="active". It will look like this:
    <jbo:Row id="rowActive" datasource="ds" action="active" ></jbo:Row>
    2) In script, you can access the attribute you want by calling rowActive.getAttribute(); ... One thing to note is that this returns an Object. You will need to type cast it before assignment. For example, say you are retrieving column Test of type Number...
    <%
    oracle.jbo.domain.Number tempNumber;
    tempNumber = (oracle.jbo.domain.Number)rowActive.getAttribute("Test");
    %>
    Hope that helped!

  • Why we are using init() in servlet

    why we are using init() in servlet
    Instead of doing in init() we can do that things in Constructor

    Hi
    In order ti be clear. Do you remeber the applet lfe cycle ?. An applet run inside a browser and a servelts runs inside a servlet container, so is the servelt container who instatiate a servlet, init and destroy, and while servlet is alive calls doService inside a thread.
    The mechanism to fill some parameters or other task is by writing the init(ServletConfig) method inherited from GenericServlet.
    To clear parameters or other clearing stuff you can use the destroy method, inherited from GenericServlet
    Hope this helps

  • Using BC4J Components with different App Servers

    Can we use BC4J with 3rd party Application Servers (WebSphere, Weblogic, iPlanet etc)?
    If so any advantages (Performance, Implementation, installation) in using these components with Oracle iAS?
    Thanks
    null

    BC4J allows different ways of deploying your application.
    1) Local Mode : where your client application and BC4J application are colocated togther and running in the same VM
    2) As a EJB session bean
    3) As a corba server object.
    Using the Local mode deployment option you can deploy the BC4J application to any appservers (weblogic, websphere, iplanet) as long as they have standard VM and if your client application is JSP or Servlet then the appservers need a JSP or Servlet engine.
    In JDeveloper 3.1 you can deploy BC4J applicaiton as EJB session bean to Oracle8i
    In JDeveloper 3.2 ( which will released in next few weeks) you can deploy BC4J application as EJB session bean to Oracle8i , Oracle iAS and weblogic .
    iAS comes preconfigured with BC4J runtime by default
    raghu

  • How can i use JSTL inside custom tag attribute

    Hi,
    I have one button tag which displays the button with round corner. I will show the button like this:
    <ep:button key="buttons.submit" name="submitBtn" styleClass="But"
              onClick='submitPage(''<c:out value='${buttonName}' />)' />
    I am getting the problem with the above code. how can i use JSTL inside the custom tags.
    Thanks in Advance,
    LALITH

    No. The details are given below:
    I have included the follwing line in web.xml file:
    <taglib>
        <taglib-uri>/tags/button</taglib-uri>
        <taglib-location>/WEB-INF/button.tld</taglib-location>
      </taglib>button.tld file
    <taglib>
         <tlibversion>1.0</tlibversion>
         <jspversion>2.0</jspversion>
         <shortname>button</shortname>
         <tag>
              <name>button</name>
              <tagclass>com.ksi.ep.web.taglib.ButtonTag</tagclass>
              <bodycontent>empty</bodycontent>
              <attribute>
                   <name>name</name>
                   <required>true</required>
                   <rtexprvalue>false</rtexprvalue>
              </attribute>
              <attribute>
                   <name>key</name>
                   <required>true</required>
                   <rtexprvalue>true</rtexprvalue>
              </attribute>
              <attribute>
                   <name>onClick</name>
                   <required>true</required>
                   <rtexprvalue>true</rtexprvalue>
              </attribute>
    </taglib>ButtonTag.java :
    public class ButtonTag extends TagSupport {
       private static final long serialVersionUID = 6837146537426981407L;
         * Initialise the logger for the class
        protected final transient Log log = LogFactory.getLog(ButtonTag.class);
         *  holds the Value of the button tag
        protected String onClick = null;
         *  holds message resources key
        protected String key = null;
         * The message resources for this package.
        protected static MessageResources messages =
                             MessageResources.getMessageResources
                                       ("ApplicationResources");
          *  (non-Javadoc)
          * @see javax.servlet.jsp.tagext.TagSupport#doStartTag()
         public int doStartTag() throws JspException {    
            StringBuffer label = new StringBuffer();         
            HttpServletRequest request = (HttpServletRequest)pageContext.getRequest();
            try {             
                   log.debug("in doStartTag()");
                   Locale locale = pageContext.getRequest().getLocale();
                 if (locale == null) {
                     locale = Locale.getDefault();
                 log.info("");
                 label.append("<a border=\"0\" style=\"text-decoration:none;color:#FFFFFF\" href=\"JavaScript:");
                 label.append(onClick);
                 label.append("\" >");
                   label.append("<table  onClick=\"");
                   label.append(onClick);               
                   label.append("\" ");
                   if(onmouseout!=null && !"".equalsIgnoreCase(onmouseout))
                    label.append(" onmouseout=\"");
                    label.append(onmouseout);               
                    label.append("\" ");
                   if(onmouseover!=null && !"".equalsIgnoreCase(onmouseover)){
                    label.append(" onmouseover=\"");
                    label.append(onmouseover);               
                    label.append("\" ");
                   if(title!=null && !"".equalsIgnoreCase(title)){
                    label.append(" title=\"");
                    label.append(title);               
                    label.append("\" ");
                   label.append("style=\"cursor:hand\" tabindex=\"1\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\" background=\"");
                   label.append(request.getContextPath());
                   label.append(System.getProperty("file.separator"));
                   label.append("images");
                   label.append(System.getProperty("file.separator"));
                   label.append("background1.jpg\" > ");
                 label.append("<tr><td width=\"10\"><img  border=\"0\" src=\"");
                 label.append(request.getContextPath());
                   label.append(System.getProperty("file.separator"));
                   label.append("images");
                   label.append(System.getProperty("file.separator"));
                 label.append("leftcorner.jpg\" ></td> ");
                 label.append("<td valign=\"middle\"  style=\"padding-bottom:2px\"><font color=\"#FFFFFF\" style=\"");
                 label.append(styleClass);
                 label.append("\">");
                 label.append(messages.getMessage(key));
                 label.append("</font></td>");
                 label.append("<td width=\"10\" align=\"right\"><img src=\"");
                 label.append(request.getContextPath());
                   label.append(System.getProperty("file.separator"));
                   label.append("images");
                   label.append(System.getProperty("file.separator"));            
                 label.append("rightcorner.jpg\" border=\"0\"  ></td>");
                 label.append("</tr></table></a>");
                 pageContext.getOut().print(label.toString());
              } catch (Exception e) {               
                   log.error("Exception occured while rendering the button", e);
                   throw new JspException(e);
            return (SKIP_BODY);
         * Release all allocated resources.
        public void release() {       
            this.name=null;
            this.key=null;
            this.onClick=null;
    }In my JSP I have mentioned the taglib directive as
    <%@ taglib uri="/tags/button" prefix="ep"%>and
    <ep:button key="buttons.submit" name="submitBtn" styleClass="But"
         onClick='overwritePreApprovals('<c:out value='${transactionalDetails['inPrepList']}' />')' />Servlet.service() for servlet action threw exception
    org.apache.jasper.JasperException: /pages/pms/coordinator/Dashboard.jsp(325,48) Unterminated <ep:button tag
    Thanks,
    LALITH

  • How to upload more than 100mb in using com.oreilly.servlet package

    hi all,
    I use com.oreilly.servlet package to upload and i use the following code to upload
    MultipartRequest mr = new MultipartRequest(request,"/tmp/saved",0x10000000);My problem is i can't upload more than 25mb, uploads upto 25mb and shows page cannot displayed err in IE,
    Pls help

    In the webserver there is most likely a configuration option for the maximum size that a request may have. So search through the manual of your particular webserver on how to change that.

  • What is the benefit of using BC4J?

    Folks,
    After working with BC4J for three months, I still can not convince my manager to use BC4J. His major arguments are:
    1. Which applications or web sites are implemented using BC4J? Are they real application or just a demo. For the time being, I even can not show him a demo, not to say any real web applications.
    2. His developers told him that the O-R mapping provided by BC4J, which is probabably one of the key benefit of BC4J can be easily coded manually with a couple of days work for the current task and we have the full control over our own code while BC4J is not an open source and the lack of the support from Oracle really worries him.
    Can someone in Jdev team give me a clear evidence to convince him?
    Thanks,
    Yibing

    [list]
    [*]With regard to struts integration with BC4J, I have done some investigations of the new release and know that BC4JActionForm is only good for simple view and does not work for a joint table view as I have reported a few days ago in this group and no response is received yet.
    This should not be the case. Should work for any view object. View objects can contain join queries with any number of updateable tables in them. Please email me the URL to the forum posting so I can track down the issue.
    [*]I have been recently told indirectly from Oracle that the consulting group at oracle are not using BC4J and instead they think that BC4J only applies to simple applications with limited number of tables and relationships.
    This is plain incorrect. We have very large applications using BC4J both internal in Oracle Applications, for Oracle iLearning, and many external customers. Many of these projects have involved (and are currently involving) Oracle Consulting. Not sure where got this information, but it is incorrect.
    [*]Other commecial O-R mapping products such as top-link should be used for large applications
    The key difference between Oracle9i TopLink and Oracle9i BC4J has nothing to do with the size of your project. The fundamental difference is that toplink is for customers who have already written a custom application framework and who require just a persistence architecture, because they've already hand-written code to implement all of the other J2EE design patterns that are required to build real J2EE applications.
    Conversely, BC4J is for customers who want a complete J2EE Application Framework (and tightly integrated, award-winning toolset to go with it) to avoid having to write, test, debug, and maintain their own application framework.
    There is simply no evidence to backup your statement that BC4J only works for small applications. I am aware of at least 20 (and by now after a summer full of training additional Oracle Apps development teams in BC4J, perhaps over 30) that are using BC4J for full-scale, self-service J2EE web applications. Our BC4J reference info pages (link in this thread above) have references to customers who are using BC4J for large applications as well.
    [list]
    Hope this helps.

  • How to use BC4J with JDeveloper 9i in a Team

    Hello
    I'm not sure if I'm to stupid, but to say the truth I didn't found the clue how to share a BC4J Application between several develeopers. Maybe someone can give me a hint.
    That's my situation:
    Our team is going to develop a web application using BC4J and BC4J-JSP, nothing special I think.
    But my problem is, that BC4J and especially the wizards refer to a lot of different files. Even simple changes often result in multiple files being changed in different parts of the project.
    Creating a view link between view objects in two packages for example changes the view objects in both packages. Also the project (.jpr) file or several "BC4J.xcfg" files are changed very often.
    So it is not easy to find parts of code from which I can say they are owned by one developer and others which are owned by another. Most often, if you have to merge the work of different developers, you have to edit the BC4J-XML-Files using an external editor. Or did someone find a better way? Please tell me!
    So, what is the best way to share code between developers?
    Should I partition the application by packages?
    - advantage:
    it allows a fine partitioning
    - disadvantages:
    it has the great danger that BC4J makes changes in other packages which will be overseen when merging.
    Should I create a projects for each developer and distribute code between the projects using libraries?
    - advantage: no unseen changes will happen, as the libraries are readonly.
    - disadvantages: no view links between view objects in different projects (Libraries) are possible! Also a lot of "load errors" can occure when updating a library, which have to be manually corrected in the dependent projects.
    Are source code management systems a real help in this problem or do they just "manage" the problem? I already tried SCM and PVCS but was not very happy with the way of working. As JDeveloper is not "really easy" to use with theese tools.
    So I would like to get any hints how other developers are dealing with this problem. Are you using BC4J with JDeveloper 9i in a team? Please tell me how do it and how you have partitioned your application.
    Thanks in advance
    Frank Brandstetter

    Hi,
    I'm not sure whether my answer is good enough for you, but it might help.
    First of all, you have to use JDev 9.0.3, because 9.0.2 has big problems with associations/view links between objects in different projects.
    Creating a view link between view objects in two packages for example changes the view objects in both packages. Also the project (.jpr) file or several "BC4J.xcfg" files are changed very often.This is not completely true in 9.0.3, as you may choose not to create an accessor in the imported object (and usually you don't need it neither!). As for bc4j.xcfg, there is a trick: define a "standard" database connection name to use all over your project! This will prevent modifying these files all the time!
    Should I create a projects for each developer and distribute code between the projects using libraries?
    - advantage: no unseen changes will happen, as the libraries are readonly.
    - disadvantages: no view links between view objects in different projects (Libraries) are possible! Also a lot of "load errors" can occure when updating a library, which have to be manually corrected in the dependent projects.I would say, projects for each application component, which by chance will be managed by a single developer at a time.
    As for the disadvantages, in 9.0.3 you are able to properly create associations and links using read-only objects. Hopefully, the release version will solve some generation inconsistencies...
    Concerning the errors that occur when modifying a library, this might be balanced by the relative independence of the components... If you are able to develop following the dependency tree, you will not meet the problem very often.
    Are source code management systems a real help in this problem or do they just "manage" the problem? I already tried SCM and PVCS but was not very happy with the way of working. As JDeveloper is not "really easy" to use with theese tools.Indeed, I do not have a SCMS really able to manage merges in the BC4J XML files... We rather try not to arrive there!
    So I would like to get any hints how other developers are dealing with this problem. Are you using BC4J with JDeveloper 9i in a team? Please tell me how do it and how you have partitioned your application.I really hope that my hints will help.
    Regards,
    Adrian

  • HOWTO: Use BC4J With or Without DB Triggers

    This HowTo describes how to use BC4J, database sequences and triggers
    and what are the ramifications.
    INTRODUCTION
    BC4J has the ability to work with database sequences in order to obtain a
    unique value when inserting records. BC4J also has the ability to
    work either with a 'before insert' trigger which automatically creates
    a new unique value for the primary key or without a trigger. When not using
    a database trigger, BC4J also has the ability to obtain the sequence value
    and set the primary key value.
    Before discussing the ramifications of using one approach or the other, let's
    show examples of how to use both approaches:
    BC4J & sequences WITH a database trigger
    and
    BC4J & sequences WITHOUT a database trigger
    HOWTO DEMONSTRATION STEPS
    To illustrate both scenarios a simple database setup script is provided which
    creates two tables:
    CUSTOMER_NT which DOES NOT have a before insert trigger and
    CUSTOMER_WT which DOES have a trigger.
    Database Install Script:
    <code>
    drop trigger customer_insert_trigger;
    drop table customer_wt;
    drop table customer_nt;
    drop sequence customer_wt_seq;
    drop sequence customer_nt_seq;
    create sequence customer_wt_seq start with 1;
    create sequence customer_nt_seq start with 101;
    create table customer_wt(
    id number,
    name varchar2(30),
    constraint
    customer_wt_pk
    primary key (id)
    create table customer_nt(
    id number,
    name varchar2(30),
    constraint
    customer_nt_pk
    primary key (id)
    prompt Inserting data...
    insert into customer_wt (id, name)
    values (customer_wt_seq.nextval, 'Mickey');
    insert into customer_wt (id, name)
    values (customer_wt_seq.nextval, 'Goofy');
    insert into customer_nt (id, name)
    values (customer_nt_seq.nextval, 'Daffy');
    insert into customer_nt (id, name)
    values (customer_nt_seq.nextval, 'Porky');
    commit
    prompt Creating trigger
    create trigger customer_insert_trigger
    before insert on customer_wt for each row
    begin
    select customer_wt_seq.nextval into :new.id from dual ;
    end;
    </code>
    The next step is to create the DEFAULT Entity Objects and View Objects using
    the Business Components Wizard.
    USING BC4J WITH A DATABASE TRIGGER
    Let's modify the entity object CustomerWt so it can use the database trigger.
    Edit the entity object CustomerWt by right-clicking in the navigator.
    Click on the 'Attribute Settings' tab and edit the ID attribute.
    - Uncheck 'Mandatory'checkbox. This allows you to insert without a value for the primary key
    - Check 'Refresh after Insert'. This obtains the value from the database generated by the trigger.
    - Check 'Updateable While New'. Id is only updateable when inserting.
    Click finish to complete the wizard. Save all and recompile the project.
    Now let's test our work.
    In the navigator right-click the application module and select 'Test..'. This will launch
    BC4J's built in tester. Connect to the application.
    In the tester double-click the CustomerWtView view object to run a test edit form.
    After the edit form renders, navigate through the existing records using the navigate
    buttons on the edit form. Now let's insert a record to execute the trigger.
    click on the '+' button to insert a record. Enter a value in the 'Name' field and commit the change.
    Observe that a new value has automatically been inserted into the Id field.
    That's it! You have successfully used BC4J and a database trigger.
    Now let's try it without a trigger..
    USING BC4J WITHOUT A DATABASE TRIGGER
    Now edit the entity object CustomerNT so it doesn't need a database trigger.
    Similar to before, edit the entity object CustomerNt by right-clicking in the navigator.
    Click on the 'Attribute Settings' tab and edit the ID attribute.
    - Uncheck 'Mandatory'checkbox.
    - Check 'Updateable While New'.
    An additional step is also required. The Create method will have to be modified to extract
    the value of the sequence.
    In the Edit EntityObject Wizard click the Java tab and select Create method and click Finish.
    The create method is generated in your Java fil e. In the Workspace view of the Navigator,
    expand the CustomerNt entity object in the navigator. Double-click
    CustomerNtImpl.java to open it in the Source Editor. In the Structure pane, double-click
    create(AttributeList). Modify the Create method so it looks like this:
    <code>
    public void create(AttributeList attributeList) {
    super.create(attributeList);
    SequenceImpl s = new SequenceImpl("customer_nt_seq", getDBTransaction());
    Integer next = (Integer)s.getData();
    setId(new Number(next.intValue())); }
    </code>
    Save and compile the project.
    Now test the ViewObject CustomerNtView using the tester as before.
    In the edit form of CustomerNTView click on the '+' to insert a record. Observe that
    just as before a new value has automatically been inserted in the ID field!
    TO USE A DB TRIGGER OR NOT TO USE A DB TRIGGER.
    Using a Database trigger sometimes preferable if you have non BC4J applications
    also sharing the database. In this case it is still safest to just let the database
    update it's own primary keys.
    If you don't have any other non-BC4J applications sharing the database, then not using
    a database trigger is perfectly acceptable and can have slightly better performance.
    The important thing to remember is that the option is yours to use either approach!
    null

    Thank you for the reply Jonathon. I am using a ViewObject which
    consist of several tables. I haven't tried the DB trigger
    approach but just using the BC4 approach in overriding the
    create method.
    Here is the parent class create as a part of the
    FasNameImpl.java file which does the job correctly.
    public void create(AttributeList attributeList) {
    super.create(attributeList);
    SequenceImpl l_seq = new SequenceImpl
    ("SEQ_CUSTOMER_ID",getDBTransaction());
    Integer l_next = (Integer)l_seq.getData();
    setCustomerId(new Number(l_next.intValue()));
    This is when I triedpassing the value to the child table. But I
    can't figure it out. I think the link is working fine if I had a
    ViewLink deployed but it doesn't look like it's doing the job
    for ViewObject.
    I am trying to call the childclass.method
    (FasCustomer.setCustomerId(l_next);
    But I am getting error.
    Thanks a lot for your suggestions,
    Kamran
    703 696 1121

  • How to use GUI_DOWNLOAD inside BSP Application event

    Hi All,
    I am facing one issue while using GUI_DOWNLOAD inside BSP Application. When the processing goes at GUI_DOWNLOAD it gives me unknown error where as the same code is working when used in report program. My requirement is to save password into excel file at my local machine. I am using FM MS_EXCEL_OLE_STANDARD_DAT to save password in excel file but this function module fail when it reach at GUI_DOWNLOAD . Can you please help me out.
    Thanks and Regards
    Pradeep Kr. Rai

    Dear Pradeep,
    Find the below link which explains a simple data download to excel from a table view.
    www.sapt echnical.com/Tutorials/BSP/Excel/Index.htm
    Try to avoid the way your using in the BSP application and it is abdicable to use the standard methods / class available like "cl_bsp_utility"
    Hope this will be helpful.
    Regards,
    Gokul.N
    Edited by: Gokul on Oct 8, 2009 9:57 AM

  • How can i upload a image file to server by using jsp or servlet.

    Hi,
    I m gurumoorthy. how can i upload a image file to server by using jsp or servlet without using third party API. pls anyone send me atleast outline of the source code.
    Pls send me anyone.
    Regards,
    Gurumoorthy.

    I'm not an applet programmer so I can't give you much advice there.
    If you want to stream the file from the server before it's entirely uploaded, then I don't believe you can treat it like a normal file. If you're just wanting to throw it up there and then listen to it, then you can treat it like a normal file.
    But again, I'm not entirely certain. You might be able to stream the start of the file from the server while you're still uploading the end of it, but it probably depends on what method you're using to do the transfer.

Maybe you are looking for

  • Internal Number Range in Vendor Master(XK01)

    Dear Gurus, During the Initial upload of vendor master in SAP the vendor codes around 3000 vendors were uploaded with an External Number range between 1000000 to 1999999 with an defined group. Now i want to deactivate the External Number range and mo

  • I can'nt get skipe to work tells me invaled port how do i get it to work with firefox

    when i use my firefox i cant seem to get skipe to work with it and it tells me invaled port so please help me fix this.

  • Physical Partitions in SAP BW

    Hi Experts, Our current implementation of SAP BW is on Db2 UDB  (the system is technically upgraded to 7.0 but the objects are still based on BW 3.5) Database DB6 Operating System AIX We are trying to find if physical partitioning is possible for inf

  • Attached libraries not executing on generated forms

    Version 6.0 designer. I am using CG$STARTUP_MODE for form that can be called from a parent form. The OFGNAVL library is attached to the form after it is generated. CGNV$.INITIALISE AND CGNV$.TIDYUP do not execute with error ORA-06508 could not find p

  • Assigning and exporting podcast artwork

    The podcast artwork that is exporting with my episodes seems to be stuck on the same one all the time.  I'm not sure how to place the correct episode artwork for each new episode of my podcasts in the GarageBank window.  For instance I have one Garag