Passing a url parameter to a method using ADF and JSP

Hi
(JDEV10.1.3 : ADF BC, JSP, STRUTS)
I have a text input on my JSP Page which I need to pass the content as an argument for the dataaction which is implemented in my application Module as a method to set the where clause of a query. I do not know How to set the Method's NDValue. I have tried:
NDValue='${pageContext.request.parameterMap[ComplexID]}'
But it always returns null
hint: ComplexID is my txtBox name on the JSP page.
I need to pass request.getParameter("ComplexID") but as an NDValue it is not accepted.
note that ComplexID is not a databind object, It has been created by myself as an HTML element.

What result do you get when you enter the following into your browser:
http://mylocalhost_IP/path/to/component/questions.cfc?method=getQuestionsXML&quizid=2 ?
(Replace http://mylocalhost_IP/path/to/component/ with the correct path to your component)
Are the results valid/well-formed XML?  Is there any extraneous text that might interferre with the XML processing?  I noticed your xPath was looking for an element called "question s" - Is that the correct name of the element in your XML?  Is there really a space in the name?
See if you can troubleshoot the issue using your browser first before adding it back into the Spry call.
Hope that helps!
- Michael

Similar Messages

  • How to create an InputSelect using ADF and JSP

    I looking for some docs/instructions on creating "an InputSelect using ADF with JSP".
    Thanks,
    BG...

    Ok here are the Steps
    1) Open the JSP editor for the page in Question.
    2) In the Data Control palette select the item that you want to become the poplist and change the "Drop As" poplist to "Single Select List"
    3) Drag the field into the page. You'll get an empty poplist which implements the <html:select> and <html:optionsCollection> tags.
    4) With the JSP editor still open click on the "UI Model" sub-tab in the Structure pane
    5) Select the field you've just dragged in - then right click to get the context menu and choose "edit"
    6) Change the List Binding Mode poplist to "LOV Mode"
    You're then taken into a couple of screens where you can select the Source VO for the poplist, and the destination dataset, along with the thing you want for the Label and the Value.

  • ADF Faces + ADF BC : how to pass an url parameter to a backend business ser

    Hi,
    I'm using latest JDev studio version SU 3.
    My project is using ADF Faces with BC4J in the service layer.
    I have a backend application module which exposes a method taking a String parameter as an input (ex: void setUsername(String username))
    I need to have a jspx page which reads a parameter passed in the url (http://localhost/faces/registerUser.jspx?username=john) and send it to the backend service method when a submit is raised on a clicked button.
    It's pretty simple when using inputtext for example but not obvious if I want to use urm param instead of inputtext.
    How do I do this ?
    Thanks

    Hi,
    Thanks a lot for your answers.
    The link http://www.it-eye.nl/weblog/2006/06/12/passing-a-url-parameter-to-model-using-adf/ is no more reachable.
    The following EL expression work for displaying the parameter inside an outputText component :
    #{facesContext.externalContext.requestParameterMap[’yourParameter&#8242;]}
    The parameter is not sent to the business service when the button is clicked.
    Thanks,
    Seb.

  • Passing custom URL parameter to a FPM app

    Hello,
    I am facing a problem when trying to pass an URL parameter to a GAF FPM application.
    The standard way by adding a parameter to the WD application and adding a parameter to the default plug in the window doesn't work for FPM... at least in my case.
    Does anyone know how URL parameters work with the FPM framework?
    Thank you and BR,
    Chris

    You just need to declare parameters which you will be using in WD Application - Parameters tab.
    To fetch parameters for application which is using FPM, you have to use following piece of code -
        wd_this->app_param = wd_this->mr_fpm->mo_app_parameter.
        CALL METHOD wd_this->app_param->get_value
          EXPORTING
            iv_key   = 'INTERFACE_MODEL'
          IMPORTING
            ev_value = wd_this->lv_interface_model.
        CALL METHOD wd_this->app_param->get_value
          EXPORTING
            iv_key   = 'MODE'
          IMPORTING
            ev_value = wd_this->lv_mode.
    Here wd_this->mr_fpm holds FPM reference and is of type ref to IF_FPM
    and wd_this->app_param holds FPM parameters reference and is of type IF_FPM_PARAMETER.
    After getting reference I'm calling methods to get individual application parameters by sending their names.
    We called this in DOINIT of component controller.
    Regards
    Manas Dua

  • Pass current url as report prarameter while using report viewer web part

    hello everybody
    is there a way to
    pass current url as report prarameter while using report viewer web part
    thanks in advance
    Sergey Vdovin

    Hi Evolex,
    Per my understanding that you want to get the current url and create an parameter to add this URL as its value, right?
    gernerally, we can use some code to get the current url but it almost impossible for us to get it automatically as value of the report parameter.
    In your senario, i suggest you to copy the url and specify values when creating parameters.
    Thanks for your understanding.
    Regards
    Vicky Liu
    If you have any feedback on our support, please click
    here.
    Vicky Liu
    TechNet Community Support

  • How to pass in a parameter into a report viewer on a jsp - and hidden

    Hi, I've built a php application and am using the java environment to enable the crystal report/viewer.  The developer was looking how to pass in a parameter into a report viewer on a jsp. Ultimately the end product we need is to get an HTML report viewer loading a report file with hidden parameters so to not expose other customer data (it's a shared database for multiple customers) preferably loaded from php using maybe the php java bridge. Would anyone happen to have any sample code or any guidance?
    <%@ page contentType="text/html; charset=UTF-8"
       pageEncoding="ISO-8859-1"%>
    <%@ taglib uri="/crystal-tags-reportviewer.tld" prefix="crviewer"%>
    <%
    // just a test to grab rpt name from GET
    String rptFile = "report_files/" + request.getParameter("rpt");
    %>
    <crviewer:viewer reportSourceType="reportingComponent" viewerName=""
    isOwnPage="true">
       <crviewer:report reportName="<%= rptFile %>" />
    </crviewer:viewer>
    Many thanks in advance!
    Mark

    I am not aware of any html tags you can pass to the viewer for parameter values.  Normally, you would load the report in code and then use the SDK with the report object to pass parameter values.

  • I use a Flexislider for my website [url removed] I want to use flash and make my website attracti

    I use a Flexislider for my website [url removed] I want to use flash and make my website attractive. Any suggestions?

    Will people be able to login to the FTP server from my website and do everything through their browser?
    Users could use web based ftp client or a 3rd party ftp client.
    Have look at the sytem the following school uses.
    http://www.glenbard.net/Glenbard_DistrictHQ/Media/MOVs/Web-BasedFTPClient.html
    Although I have not setup this type of thing up myself googling around shows a few tutorials using PHP or Java based ftp clients.
    have a look at this article..

  • Error in Creating Custom Business Methods using ADF Business Comp. Tutorial

    I've been working with Jdev 10g Preview for a while. Now that we have Jdev 10g, I have to unlearn some of the Preview methods and learn the "real" way of doing things. To that end, I went out to the "Creating Custom Business Methods using ADF Business Components" tutorial. Unfortunately, I've found what I think is a mistake in the example code.
    Specifially, ADF treats the default iterator on View Objects differently than previous BC4J versions. In the older versions, the iterator was positioned before the first row when you first executed a query. In that case, the hasNext() method was used to see if you had any rows at all. In ADF, however, the default iterator is positioned at the first row. So, if your query only returns one row, then the hasNext() method returns false!
    Here's the code posted in the tutorial:
    public Number getDeptSalaryTotal(String dept_id)
    // get a department view object
    DepartmentsViewImpl dept = getDepartmentsView1();
    dept.setWhereClause("DEPARTMENT_ID = " + dept_id);
    dept.executeQuery();
    dept.first();
    EmployeesViewImpl emps = getEmployeesView3();
    Number salaryTotal = new Number(0);
    while (emps.hasNext() )
    Row empsRow = emps.next();
    salaryTotal =
    salaryTotal.add((Number)(empsRow.getAttribute("Salary")));
    return salaryTotal;
    As you can see, this is coded using the pre-10g semantics. It checks hasNext() at the top of the while loop. If there is only one Employee in the Department, hasNext() will return false since the emps View Object will already be positioned at the first and only row. There won't be a next row. So, the salaryTotal will be zero instead of the correct value. Alternatively, if there is more than one row, then hasNext() will be true, but the routine will skip the first row and start totalling salaries from the second row on.
    The routine should be recoded as follows:
    public Number getDeptSalaryTotal(String dept_id)
    // get a department view object
    DepartmentsViewImpl dept = getDepartmentsView1();
    dept.setWhereClause("DEPARTMENT_ID = " + dept_id);
    dept.executeQuery();
    dept.first();
    EmployeesViewImpl emps = getEmployeesView3();
    Number salaryTotal = new Number(0);
    Row empsRow = emps.first(); // Get the first row
    while (empsRow != null ) // while we have a row
    salaryTotal =
    salaryTotal.add((Number)(empsRow.getAttribute("Salary"))); // add in the salary
    empsRow = emps.next(); // get the next row
    return salaryTotal;
    I haven't actually executed this code, so there may be a typo or two in there. However, the basic idea is sound -- I think!
    Please update the tutorial so we don't mislead people right at the start! :-)

    Gary:
    I have two questions for you:
    1) Could you post the preferred code here?
    2) Why is it the preferred method? I would think that creating and destroying another object (the temporary iterator) would be a bad thing.

  • File Upload using struts and jsp

    Hi,
    Anybody have sample coding for uploading files into the database using struts and jsp.
    Thanking you in advance for providing the sample coding.
    Veena

    Hi Veena,
    In Strutsconfig.xml you have to configure data sources like this
    **************strutsconfig.xml******
    <data-sources>
    <data-source
    type="org.apache.common.dbcp.BasicDataSource">
    <set-property property="driverClassName"
    vlaue="oracle.jdbc.driver.OracleDriver"/>
    <set-property property="url" vlaue="jdbcracle:thin:@(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=localhost)(PORT=1521))(CONNECT_DATA=(SID =ORCL)))"/>
    <!-- <set-property property="url"
    vlaue="jdbcracle:thin:@127.0.0.1:1521:ORCL"/>-->
    <set-property property="username"
    vlaue="scott"/>
    <set-property property="password"
    vlaue="tiger"/>
    </data-source>
    </data-sources>
    Now here is how to get data source
    public class LookupAction extends Action
    public Double getQuote(String symbol,
    HttpServletRequest request)
    throws Exception
    Double price=null;
    Connection conn=null;
    Statement stmt=null;
    ResultSet rs=null;
    DataSource dataSource=null;
    try
    dataSource = getDataSource(request);
    conn= dataSource.getConnection();
    stmt= conn.createStatement();
    rs= stmt.executeQuery("select * from stocks where" + "symbol='" + symbol +"'");
    if (rs.next())
    =======================
    After you can use the coding what I posted earlier.
    For that you need to create a table with attachment as a CLOB col.
    then with prepared statement I am setting value .
    Plz try your self every thing ok you can get that.
    all the best
    bye
    sudheen

  • When to use servlets and jsp in an application like  shoping cart?

    Hi All
    I m going to design and implement a web application using servelts and jsp. I am still at its requirements analyze stage.
    The application is almost likely a shopping cart. So if any of you have the deep knowledge about this domain with servlets and jsp please help me for a good design. What I realy need to know is that
    1. what are the core requirements for a shoping cart ?
    2. use cases ?
    3. best way to follow mvc with servlets and jsp for it?
    you can answer to this at the abstract level. no need to go in detail.
    if you have any documents like design and use cases mail me to [email protected]
    your cooperation is highly appreciated in this regards.

    Look into this kid
    http://www.apl.jhu.edu/~hall/java/Servlet-Tutorial/Servlet-Tutorial-Session-Tracking.htm

  • Download local file using Servlet and JSP

    Hello,
    I will like to use a browser to download file on local system using serlvet and Jsp technology. Does anyone have any idea how to do it?
    Any comment will be appreciate.
    Thanks

    Well you can just put the file in a folder that is accessible to the web server. Then have a link point to that file. That will cause the web browser to download the file.
    hattan

  • URGENT.........File Upload using Servlets and jsp

    I am a new servlet programmer.......
    iam using tomcat server......
    can any one pls help in writing code for file upload using servlets and jsp without using multipart class or any other class like that....
    Please URGENT..

    Slow down! "Urgent" is from your perspective alone. I, myself, am not troubled or worried in the least.
    hi ugniss
    thanks for ur reply....sorry i was not
    y i was not asked not to use multipart class or any
    other class like that...is there any other
    possibility to do file uploading from jsp to
    servlet...
    Just as an aside, a JSP is a Servlet. But even if I move beyond that, the question does not make sense. If you want a "JSP to upload to a Servlet", then simply do so in memory. You are still (likely) within the same scope of a given request. However, if instead you are referring to a JSP that is displayed on a browser, then really you are talking about HTML, which is what the browser will receive. And since you are now talking about a browser, your only real, viable option is a multi-part file upload. So, it is either server or it is browser. And either way, the question leads to very established options, as outlined above.
    the main concept is.. in the browser the user selects
    a particular file and clicks the button upload..after
    clicking upload the jsp should sent the file to the
    servlet in streams...there the servlet gets in and
    saves in a server location........this is wat i hav
    to do...
    Okay. So, after reading my previous (redundant) paragraph, we have arrived at the crux of the issue. You have a JSP that will be output as HTML to a client (browser) which you want to upload content to your server (handled by a Servlet). So, you are now stuck again with multi-part. The requirement to not use multi-part is non-sensical. You can overcome it, say, if you write your own applet or standalone Swing client. However, if your users are invoking this functionality from a browser, you are limited by the options that W3C has provided you. Use multi-part.
    is there aby possibilty to do this.....can any one
    pls help....Take the advice to download and review Jakarta Commons FileUpload. Inform your management that their requirement makes no technical sense. Research on your own. There are dozens of examples (and tutorials) on file upload using multi-part. Embrace it. Live it. Love it.
    - Saish

  • Reading url parameter  in HANDLEDEFAULT method

    Hi,
    May be I am doing something very silly but I am trying to read URL parameter in my HANDLEDEFAULT method of  MAIN window , and I am trying to define URL paramter as Method parameters but its gives me run time exception every time 'The ASSERT condition was violated.' 
    my simple paramter is like this  HEADER_ID   TYPE  importing  associated type   STRING
    Can any body help me why this error happens.
    Regards,
    Gaurav

    Hello, Gaurav,
    Have you tried something like this:
      DATA: l_url_parameters          TYPE tihttpnvp,
            l_url_parameter           TYPE ihttpnvp.
      wdevent->get_data( EXPORTING name  = if_wd_application=>all_url_parameters
                         IMPORTING value = l_url_parameters ).
      READ TABLE l_url_parameters WITH KEY name = 'parameter_name'
                                  INTO l_url_parameter.
      IF sy-subrc EQ 0.
    *    your value treatment here
      ENDIF.
    There's no need to declare your parameters as method parameters.
    Regards,
    Andre

  • Use UIX and JSP together

    I have some existing jsp application . I want to integrate it with UIX application that is generated from JHeadStart . jsp application is just 10% of whole project.
    I am not sure this is a good way or not . May be We should use JHeadstart to generate JSP more than UIX . but I think it 's more powerful if I use JHeadstart to generate UIX application .
    What do you recommend for this ?
    and if we have to use both together . How dose JSP application pass parameter to UIX application ? and How dose UIX pass parameter to JSP ?. and How UIX use the parameter that 's sent form JSP ?
    thanks in advance

    If JSP is only 10% you might want tpo consider migrating these pages to UIX.
    If this is not an option, you should be able to use both UIX and JSP pages. However, make sure you create separate struts-config.xml files for the JSP-based subsystem and the UIX-based subsystem. This requires two se[parate ViewController projects, that act as one web application. The same setup that has been aplied to Th JHeadstart demo application in Jhs 10.1.2.1. Check out this article from Duncan Mills as well:
    http://www.oracle.com/technology/products/jdev/howtos/10g/StrutsMultiConfigs/struts_multiconfig_howto.html
    One addition to this articel: the source path property of the ViewController projects shopuld be the same as well.
    As far as communication between the pages is concerned: this is no different then between UIX pages. You can pass request parameters around, and since the pages are running in the same web app, they share the same HttpSession.
    Steven Davelaar,
    JHeadstart Team.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • Using javadoc and jsp

              I'm supposed to javadoc my application. Can this be done? Any advice or
              tips? References to documentation?
              Thanks
              

    I tried it out and it doesn't work. The jsp compiler inserts its own
              description before the class declaration. The rest of the information
              generated by javadoc is pretty much useless. Clearly javadoc and jsps were
              never meant to go together. Too bad.
              * This code was automatically generated at 11:01:15 AM on Dec 7, 2000
              * by weblogic.servlet.jsp.Jsp2Java -- do not edit.
              * Copyright (c) 2000 by BEA Systems, Inc. All Rights Reserved.
              "Jacob Meushaw" <[email protected]> wrote in message
              news:3a2fa46c$[email protected]..
              > That is a great question that I have been thinking about myself. Would it
              be
              > possible to use the "keepgenerated" parameter with the JSPServlet to
              > generate the straight java code from the JSPs and then run javadoc on
              those?
              > Or does the JSPServlet strip out all the comments?
              >
              > Just an idea,
              > -jacob
              >
              > "Peter Bismuti" <[email protected]> wrote in message
              > news:3a2f02c7$[email protected]..
              > >
              > >
              > > I'm supposed to javadoc my application. Can this be done? Any advice
              or
              > > tips? References to documentation?
              > >
              > > Thanks
              > >
              > >
              >
              >
              

Maybe you are looking for

  • Acrobat 9 Pro: Install Problem "not enough disk space"

    Hi: I just bought and downloaded Acrobat Pro 9 from the Adobe site and took the following steps: 1) Uninstalled Acrobat Pro 7 & rebooted 2) expanded installation copy onto Desktop 3) Copied Install to CD 4) Installed and chose both "Typical" & "Compl

  • Many queues in Transactional RFC (SM58)

    Hello, There are many queues under transactional RFC(SM58) what should i do? Can i delete the Queue's or execute that? What is the mean of Execute LUW's and Debug LUW's ,when we wil use it? Highly appriciate your immediate replies. Thanks in advance.

  • ORDER get status OPEN after reversal of billing document.

    Hi Experts, Can someone help me with the following issue? I've created an order with VA01. After that i've created a bill with VF01. Then I had to reverse the bill. After the reverse of the bill the order overall status goes back to OPEN The reversal

  • How operator contains works on View Criteria?

    Hi im using Jdev 11.1.1.2.0, and i need to filter a VO field, i was wondering how to use the operator contains? i've tried to use the operators AND || && but nothing Any idea? Edited by: ThDn on Apr 26, 2010 11:21 AM

  • Problems with 10.4.4 update also

    Updating to 10.4.4 from 10.4.3 has caused me some problems. I did not know about the Archive and Install, so I did not do that. The update lost some of my options on the menu bar (such as my VPN connections and special key mappings for locking the co