How do I pass input values from a html page to a jsf page

hi,
In my project,for front view we have used html pages.how can I get input values from that html page into my jsf page.for back end purpose we have used EJB3.0
how can I write jsf managed bean for accessing these entities.we have used session facade design pattern and the IDE is netbeans5.5.
pls,help me,very urgent
thanx in advance

Simplest way is to rewrite html page into jsf page.
You can use session bean in your managed bean like this:
import javax.naming.Context;
import javax.naming.InitialContext;
public class ManagedBean {
private Context  ctx;
private Object res;
// session bean interface
private Service service;
          public ManagedBean() {
            try{
                 ctx = new InitialContext();
                 res = ctx.lookup("Service");
                 service = (Service) res;
           catch(Exeption e){
}Message was edited by:
m00dy

Similar Messages

  • How do I pass input values from an OTL timecard to a Fast Formula (FF)?

    Hi - I hope my question is a simple one, but after hours of searching I have a feeling it is not. I currently have a FF rule that checks if benefit hours were entered in whole or half day increments. If not, an error is shown after 'Continue' is clicked. I fully understand the setup of this rule and all I want to do is enhance it a bit. I want to verify if the Task Code and Expenditure Type code combination that is coded is correct. If they are not, I want to flag it. My issue is: I have not been able to pass the values of Task Code and Expenditure Type to the FF successfully. They are not database values and any aliases I try do not work (I assume they would be input variables passed to the FF). Any tips would be appreciated.
    Thank you,
    Rob

    You should read these values from the attributes pl/sql tables in your FF code. The timecard related info gets passed to the FF as context when you are creating a time entry rule FF.
    --Shiv                                                                                                                                                                                                                                                                                                                                                                                               

  • How do I pass selected values from dynamic LOV to Command SQL in Oracle

    My environment:
    Crystal 11
    Oracle 10
    I've created and tuned a SQL script for a report.  In the Database Expert, I've copied the SQL into a Command.   I've modified the Command to create 3 parameters. 
    I need help with the following:
    1) How do I create a dynamic, cascading LOV and associated prompt group for the three parameters defined in the Command?
    2) How do I pass the user selected valueS from the prompt group into the Command SQL as limits applied to the query executed against the database?

    I have the same problem with same environment .
    The main report is having a  2 level cascading dynamic parameters.
    I created a sub report with a command as below.
    *select * from (*
    select DATUM,MSEC,CNT,B1_NAME,B2_NAME,B3_NAME,ELEM_NAME,INFO_NAME,m.INFOTYPE,V.NAME,rank()
    over (partition by B1_NAME,B2_NAME,B3_NAME order by DATUM desc ,MSEC desc,CNT desc) currentRank
    from MESSAGES m,INTYDE i,VANAME v
    where  DATUM <=SYSDATE  and trim(B1_NAME)='{?B1Name}'
    and trim(B2_NAME)='{?B2Name}'
    and m.INFOTYPE=i.INFOTYPE
    and i.VALUE_NAME_NUMBER = v.VALNUM) where currentRank=1
    I needs to pass cmbination of B1Name and B2Name from main report. I created a formula like
    formula=Join({?B1Name},{?B2Name}),'|');  But this is showing some error.
    and How I will substitute this in my command . As I new to Crystal XI  help expected.

  • How to get input value from a HTML form?

    Hi,
    I use URL class to connect to a simple HTML file. In the returned page there is a form with hidden input with default value. How can I get the values?
    Thanx.

    By parsing the HTML.

  • How can I pass a value from one application to another through URL

    I am passing a value APP_USER from one application to another application (item is P_ASK_U) through navigation bar entrees URL.
    This is working with in the application..(javascript:popupURL('f?p=&APP_ID.:165:&SESSION.::&DEBUG.::P_ASK_U:#&APP_USER.#') )
    This one is not passing the value, eventhough it open the application..
    javascript:popupURL('http://htmldb.oracle.com/pls/otn/f?p=35129:1:::P_ASK_U:&APP_USER.');
    Is there any syntax error or is it not possible, please let me know..
    Thanks
    Venu

    Hi Scott,
    You are right, the first one do not need # character.
    In the Doc it is mentioned as....
    Pass the value on a URL reference using f?p syntax. For example:
    f?p=100:101:10636547268728380919::NO::MY_ITEM:ABC
    I am using the following URL, it pops up the external application, but it is not passing the APP_USER value to the page item of that application.
    javascript:popupURL('http://htmldb.oracle.com/pls/otn/f?p=35129:1::P_ASK_U:&APP_USER.');
    sorry I still do not know what I am missing..
    Thanks
    Venu

  • How can I pass a value from the datagrid to my textinput

    Hi i am new in adobe flex!
    I have only one row in my datagrid and it has 5 dataField. Those dataFields are id, ln, fn, kurs, yr. I want to pass those value into a textinput respectively.
    Heres my code:
    <mx:DataGrid x="396" y="10" width="110" height="124" id="dginfo" enabled="true" dataProvider="{studinfo.lastResult.datas.data}" creationComplete="studinfo.send()" editable="false" visible="true">
                            <mx:columns>
                                <mx:DataGridColumn headerText="C0" dataField="username" visible="false"/>
                                <mx:DataGridColumn headerText="C1" dataField="id"/>
                                <mx:DataGridColumn headerText="C2" dataField="ln"/>
                                <mx:DataGridColumn headerText="C3" dataField="fn"/>
                                <mx:DataGridColumn headerText="C4" dataField="kurs"/>
                                <mx:DataGridColumn headerText="C5" dataField="yr"/>
                            </mx:columns>
                        </mx:DataGrid>
    I want to pass it here (code)
    <mx:TextInput backgroundColor="#ABA5A5" editable="false" enabled="true" color="#000000" horizontalCenter="-50" verticalCenter="-71" id="idview" text="{data.id}"/>
                        <mx:TextInput  id = "idview" editable="false" enabled="true" text="{data.ln}"/>
                        <mx:TextInput  id="lnview"editable="false" enabled="true"text="{data.fn}"/>
                        <mx:TextInput id="fnview" editable="false" enabled="true" text="{data.kurs}"/>
                        <mx:TextInput backgroundColor="#ABA5A5" editable="false" enabled="true"  id="yrview" text="{data.yr}"/>
    My problem is that this code won't work, it won't diplay anything...:D

    it must not display anything as data.ln doesnot have any value. in your code, in the text property of textfield, data is considered as a property of your application, a dynamic object; so even it doesnot have ln property, it is not showing error, neither displaying anything.
    do you mean to populate your textfields if the datagrid row is selected? if so:
    <mx:TextInput  id = "idview" editable="false" enabled="true" text="{dginfo.selectedItem.ln}"/>
    if you want to populate the same data without caring if it is selected in datagrid, you should not think like you are getting data from datagrid, instead, you are getting your values directly from the studinfo.lastResult
    in such:
    <mx:TextInput  id = "idview" editable="false" enabled="true" text="{studinfo.lastResult.datas.data.ln}"/>
    note: if your result contains more than one data, you should treat it as array:
    studinfo.lastResult.datas.data[0].ln

  • How do I pass a value from a selected datagrid row to a popup

    I am working on a project tracking application in flex and need to pass the value of one of the rows from the datagrid to a popup. We have a screen with 2 data grids. The first datagrid lists the projects, their start, and end date and the project owner. The datagrid below the first datagrid lists the tasks for that specific project listed in the datagrid above. When you click on the project name above, the datagrid below is populated with the tasks. Within the tasks datagrid are start and end date boxes.
    What I need to do is be able to pass the project ID from the original datagrid into a popup that is called when a user changes the date of a project task. The popup is designed to submit a reason for why the user is changing the date on the task. In short, when they submit a reason, I need the project id passed from the datagrid into the popup so when submit is clicked, the proper row in the DB table is update via a CFC. Thank you.

    I tried that, but when I try to build the project, I get the error that there is a call to an undefined value. Here is code:
    Project Component:
    <?xml version="1.0" encoding="utf-8"?>
    <mx:VBox xmlns:mx="http://www.adobe.com/2006/mxml"
        width="100%" height="100%" creationComplete="init();" xmlns:mxml="components.mxml.*">
        <mx:Script>
            <![CDATA[
                import mx.events.ListEvent;
                import mx.controls.dataGridClasses.DataGridColumn;
                import mx.rpc.events.ResultEvent;
                import mx.managers.PopUpManager;
                import mx.core.IFlexDisplayObject;
                import components.mxml.NewProject;
                import components.mxml.NewTask;
                import components.mxml.dateChangeNotice;
                import mx.controls.Alert;
                private function init():void{
                    roGetData.getProjects();
                    //roGetData.getTasks();
                private function projectClick(event:ListEvent):void{
                    //Alert.show(dgProjects.selectedItem.projectID);
                    roGetData.getTasks(dgProjects.selectedItem.projectID);
                private function refreshProjects(event:MouseEvent):void{
                    roGetData.getProjects();
                private function ResultEvent_Projects(event:ResultEvent):void{
                    dgProjects.dataProvider = event.result;
                private function ResultEvent_Tasks(event:ResultEvent):void{
                    adgTasks.dataProvider = event.result;
                private function ResultEvent_UpdateTasks(event:ResultEvent):void{
                    Alert.show('Your task was updated');
                private function showNewProject():void{
                    var newProjectWindow:IFlexDisplayObject =
                        PopUpManager.createPopUp(this, NewProject, true);
                    newProjectWindow.addEventListener(MouseEvent.CLICK, refreshProjects);
                private function showNewTask():void{
                    var newTaskWindow:IFlexDisplayObject =
                        PopUpManager.createPopUp(this, NewTask, true);
                private function dateFormat(item:Object, column:DataGridColumn):String{
                    return dateFormatter.format(item[column.dataField]);
                    //Function calls the Reason popup window
                //private function changeReason():void{
                    //Create Popup Window
                    //var resultWindow:IFlexDisplayObject =
                    //PopUpManager.createPopUp(this, dateChangeNotice, false);
            ]]>
        </mx:Script>
        <mx:RemoteObject id="roGetData" destination="ColdFusion" source="projectTracker.components.cfc.controllers.getController">
            <mx:method name="getProjects" result="ResultEvent_Projects(event);" fault="Alert.show(event.fault.faultString);" />
            <mx:method name="getTasks" result="ResultEvent_Tasks(event);" fault="Alert.show(event.fault.faultString);" />
        </mx:RemoteObject>
        <!--<mx:RemoteObject id="roUpdateData" destination="ColdFusion" source="projectTracker.components.cfc.controllers.updateController">
            <mx:method name="updateTasks" result="ResultEvent_UpdateTasks(event);" fault="Alert.show(event.fault.faultString);" />
        </mx:RemoteObject>-->
        <mx:DateFormatter id="dateFormatter" />
        <mx:HBox width="100%">
            <mx:Label text="Projects:" />
            <mx:Button label="Insert New Project" click="showNewProject();"/>
        </mx:HBox>   
        <mx:Panel width="100%" height="45%" title="Projects">
            <mx:DataGrid id="dgProjects" width="100%" height="100%" itemClick="projectClick(event);" dataProvider="">
                <mx:columns>
                   <mx:DataGridColumn dataField="projectID" headerText="ProjectID" visible="false" />- I Need to pass this value
                    <mx:DataGridColumn dataField="name" headerText="Project" />
                    <mx:DataGridColumn dataField="startDate" headerText="Date Started" labelFunction="dateFormat" />
                    <mx:DataGridColumn dataField="endDate" headerText="Completion Date" labelFunction="dateFormat" />
                    <mx:DataGridColumn dataField="description" headerText="Description" />
                    <mx:DataGridColumn dataField="statusName" headerText="Status" />
                    <mx:DataGridColumn dataField="ownerName" headerText="Owner" />
                </mx:columns>
            </mx:DataGrid>
        </mx:Panel>
        <mx:Panel width="100%" height="45%" title="Project Tasks">
            <mx:AdvancedDataGrid id="adgTasks" width="95%" height="100%" variableRowHeight="true">
                <mx:columns>
                    <mx:AdvancedDataGridColumn dataField="taskID" visible="false" width="50" />
                    <mx:AdvancedDataGridColumn dataField="name" width="25" />
                    <!--<mx:AdvancedDataGridColumn dataField="startDate" headerText="Date Started" />
                    <mx:AdvancedDataGridColumn dataField="endDate" headerText="Completion Date" />-->
                    <mx:AdvancedDataGridColumn id="descript" dataField="description" headerText="Description" width="50"/>
                    <mx:AdvancedDataGridColumn dataField="ownerID" headerText="Owner" width="25"  />
                    <mx:AdvancedDataGridColumn dataField="notes" headerText="Project Notes" width="50"/>
                    <mx:AdvancedDataGridColumn dataField="Dates" headerText="Dates" width="50"/>
                </mx:columns>
                <mx:rendererProviders>
                    <mx:AdvancedDataGridRendererProvider dataField="taskID" columnIndex="5">
                        <mx:renderer>
                            <mx:Component>
                                <mxml:dgDateHSlider startDate="{data.startDate}" endDate="{data.endDate}"/>   
                            </mx:Component>
                        </mx:renderer>
                    </mx:AdvancedDataGridRendererProvider>
                </mx:rendererProviders>
            </mx:AdvancedDataGrid>   
        </mx:Panel>
        <mx:HBox width="100%">
            <mx:Label text="Tasks:" />
            <mx:Button label="Insert New Task" click="showNewTask();"/>
            <mx:Spacer width="200"/>
        </mx:HBox>
    </mx:VBox>
    Popup Components
    <?xml version="1.0" encoding="utf-8"?>
    <mx:TitleWindow xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" width="400" height="400" title="Reason for Date Change" backgroundColor="#E5E4E4">
    <mx:Script>
        <![CDATA[
                 import mx.events.ValidationResultEvent;
                import mx.rpc.events.ResultEvent;
                import mx.managers.PopUpManager;
                import mx.core.IFlexDisplayObject;
                import components.mxml.NewUser;
                import mx.controls.Alert;
                import components.mxml.Projects;
                import components.mxml.NewTask;
            //Clear Text Area Function
           public function Clear():void{
                reasonText.text = "";
            //function to send notes to db via RO
            public function writeNotes():void{
      into here-->    updateReason.reasonUpdate(taskID.selectedItem,reasonText.text);  taskID.selectedItem is not recognized. It errors on compile
            //remote object Results Event
            public function reasonResult(event:ResultEvent):void{
                Alert.show("Label update successful, thank you!");
                Clear();
        ]]>
    </mx:Script>
    <!--Update Remote Object-->
    <mx:RemoteObject id="updateReason" destination="ColdFusion" source="projectTracker.components.cfc.controllers.createController">
        <mx:method name="reasonUpdate" result="reasonResult(event);" fault="Alert.show(event.fault.faultString);"/>
    </mx:RemoteObject>
    <!--Reason Text Area-->
        <mx:TextArea x="19" y="60" width="90%" height="246" maxChars="1000" wordWrap="true" enabled="true" id="reasonText"/>
        <mx:Button label="Update" click="writeNotes()" right="65" bottom="0"/>
        <mx:Button label="Exit" click="PopUpManager.removePopUp(this);" right="10" bottom="0"/>
        <mx:Text text="Please Specify your reason for changing the dates of this task." width="90%" fontWeight="bold" top="10" horizontalCenter="0"/>
    </mx:TitleWindow>

  • How can I pass a value from Client to EntityImpl class?

    Hi everyone,
    I am using ADF BC to develop my Application.
    I want to do something in the EntityImpl class.
    My job needs a value from Client.
    I can't find any way to slove the problem.
    Is there anyone have an ideal, please tell me.
    Thanks,
    Tuan Vu Minh
    FPT Software Solution Company (Oracle partner)
    FPT Coporation
    Add: 3th Fl., 51 Le Dai Hanh Builiding,
    Hai Ba Trung Dist,
    Hanoi,
    The Socialist Republic of VietNam
    Tel: (84,4) 9745476
    Fax: (84,4) 9754475
    Email: [email protected]
    Website: http://www.fss.com.vn , http://www.fpt.com.vn

    Firstly, let me state that I'm not a Swing programmer, so your mileage may vary. However I don't think a Swing solution is what you need. ADF BC will do this for you.
    Assumptions on my answer:
    1) You're generating the log_id from a database sequence and it is automatically populated in the UserLog table.
    2) You have 2 VOs, namely UserLogView and ActionLogView based on the EOs.
    Create a View Link between each VO making UserLogView the master.
    In your UI, once the user has inserted into UserLogView, include a bound create button for the ActionLogView such that it creates an associated ActionLogView record for the user when they wish to enter the log details. ADF BC will populate the ActionLogView Log_id with the parent's UserLogView log_id automatically. You'll then need to navigate to the ActionLogView screen to allow the user to enter the rest of the details.
    As such, you don't need to expose the log_id to the client, ADF BC will take care of the population of the log_id correctly for you when creating the detail record.
    Another approach may be to define one VO encompassing both EOs, where the ActionLog is a reference. Look at the JDevelope help page "View Object Wizard - Entity Objects Page", specifically at the "Reference" section for more info. You'll need to test out the updateable flag for both EOs defined within the VO to ensure you can update the values of both.
    Test this out in the Business Components Browser before writing the UI to see if the ADF BC solution works, and saving you time in writing the UI.
    Hope this helps.
    CM.

  • How can i pass parameter values from html to a shell script

    Hi Guys...
    I had a requirement where i need to execute a sql statement and print the output in HTML page. This report has parameters to enter. So i created a HTML form which accepts parameters. When the submit button is pressed, the action tag in the form invokes unix shell script file. It will open sqlplus and run the sql script file .sql and print the output in the HTML page.
    sql script contains the query and some set options which prints the output in HTML page. Like "SET MARKUP HTML ON"... The query has some parameters like "select * from emp where empno = &&empnumber. I will use the same name "empnumber" while created the HTML parameter form like " <input type = "text" name="empnumber" size="10" align="left">.
    user sees this parameter form and enters some value in to that empno text box.
    My question is how can i catch these parameter values in a shell script and pass it to the sql script to execute it.
    Help Appreciated
    Thanx

    This is a A Bad Idea (tm). This type of CGI processing is old and were (and still is) full of security holes. Very easy to inject stuff (Unix commands and SQL) into it.. To get those parameters into SQL*Plus requires using Unix shell commands to process it - and something like a backquote allows all kinds of nasty stuff to be injected. The Unix shell was never designed to be used as a secure CGI environment.
    There are far better and far superior alternatives. Perl (with Perl_DBI) and PHP (using Zend Core for Oracle) come to mind as web scripting languages.
    Even easier is using HTMLDB. Very few moving parts. Is free. Supports Oracle 9.2 and 10G.

  • How do I pass multiple values from a text box to an update statement

    I hope this does not sound to lame. I am trying to update multiple values Like this:
    Code|| Computer Desc || Computer Price || Computer Name
    SEL1 || Apple macbook || 1564 || Apple Macbook Basic
    SEL2 || Dell 630 || 1470 || Dell Latitude
    I want to change all six values at once in one update statement based on the Code, I can't find a good tutorial/example to help me.
    Can anyone point me in the right direction?
    Thanks so much,
    Laura

    You can do conditional updates with decode or case statements e.g.
    SQL> create table t as
      2  select 'SEL1' as code, 'Apple macbook' as comp_desc, 1564 as comp_price, 'Apple Maxbook Basic' as comp_name from dual union
      3  select 'SEL2', 'Dell 630', 1470, 'Dell Latitude' from dual
      4  /
    Table created.
    SQL>
    SQL> update t
      2  set comp_desc = CASE code WHEN 'SEL1' THEN 'Test1' Else 'Test2' END,
      3      comp_price = CASE code WHEN 'SEL1' THEN 1234 Else 2345 END,
      4      comp_name = CASE code WHEN 'SEL1' THEN 'Test1 Name' Else 'Test2 Name' END
      5  /
    2 rows updated.
    SQL>
    SQL> select * from t
      2  /
    CODE COMP_DESC     COMP_PRICE COMP_NAME
    SEL1 Test1               1234 Test1 Name
    SEL2 Test2               2345 Test2 Name
    SQL>

  • How to capture text input value by user in a LOV search popup page?

    I need to capture the input by the user in LOV search page. I added one controller in the LOV region, and the flow is also working, but what I need to hold the search input in the search popup page. Also do you know what is the id of " Search Term" text input? then I can try to hold the value in PFR of the CO.

    Hi Sandeep,
    Yes, as of now I need to populate blank, so I need to modify the SQL, therefore I need to capture the value which is given by the user. I am trying to capture the value through passive criteria, but not able to get the result. I added below code in PFR of lov region controller,
           Dictionary passiveCriteriaItems = pageContext.getLovCriteriaItems();
           String lov = (String)passiveCriteriaItems.get("SwitchLOV");
          if ((lov != null) && !("".equals(lov)))
               throw new OAException(lov, OAException.INFORMATION); 
    SwitchLOV is a lov map I have added in the LOV, and
    Programmatic Query set to true. and
    LOV Region Item is the id for which user searches.
    I am getting null in the "lov" where i have give some value in the search field.
    Is this would be the way?
    I dont understand where is the issue, Please suggest.

  • How can i get the value from a HTML Form

    hi,
    I am using HTML form (logfrm). there are userId field,password field, submit button,reset button, and a link.
    when i click on the link, it should fetch the value of userid.
    How it is possible?
    AE

    use jsp:
    which lets you embed java statments in your html -so you when you click on the link you can use request.getParameter("userID") to get the userid.
    Ideally with html forms use a combination of jsp and java beans, where the fields in the form are also fields in your java bean, which you can access through setters and getters.
    google for some jsp tutorials.

  • How to avoid the whitespace before the first html output in a JSF page?

    1     
    2
    3
    4
    <?xml version="1.0" encoding="utf-8"?>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="pt-br" lang="pt-br">So, I think the reason is because there are some taglibs like:
    <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %>
    <%@ taglib uri="http://java.sun.com/jsf/core" prefix="f" %>
    <%@ taglib uri="http://jakarta.apache.org/struts/tags-tiles" prefix="tiles" %>is it possible to avoid that?

    humm
    that's right!
    it's because, a friend has asked me about that in order to do the output HTML 100% valid...and it is, but with some warnigs according W3C
    thank you!

  • Passing Input values to Adapter Module

    Hi
    I have write some simple adapter module in my sender file adapter.
    in order to make it more flexible i need to pass 2 input parameters  at run time so that I can update the Values in SAP tables using JCO CALL along with filename.
    please advise how to get pass input value from my ejb module.
    regards
    Gabriel

    >
    Gabriel Sagaya Selvam wrote:
    > Hi
    > I have write some simple adapter module in my sender file adapter.
    > in order to make it more flexible i need to pass 2 input parameters  at run time so that I can update the Values in SAP tables using JCO CALL along with filename.
    >
    > please advise how to get pass input value from my ejb module.
    >
    > regards
    > Gabriel
    refer this blog - https://www.sdn.sap.com/irj/scn/weblogs?blog=/pub/wlg/6107. [original link is broken] [original link is broken] [original link is broken]
    you can add flexibility by adding the module key parameters. Base the code as a reference where the author uses parameters configured in the adapter to be used to in the logic

  • How to pass the value from JSP or HTML  to Applet

    Plz reply ....How can we pass the value from the JSP Page or from HTML page to Applet embedded in same page....

    Hi,
    <applet codebase = "."
    archive = foo.jar"
    code = "com.bar"
    name = "bar"
    id = "bar"
    width = "<%=Request["width"] %>"
    HEIGHT = "<%=Request["appHeight"] %>"
    hspace = "0"
    vspace = "0"
    align = "middle"
    alt     = "Applet is Loading..."
    >
         <param name="LANGUAGE"                value="<%=Request["lan"] %>">          
         <param name="LOGOUT_USER_URL"           value="EndSession.asp">
         <param name="DATA_READ_INTERVAL"      value="10000">
         <param name="REFRESH_INTERVAL"           value="5000">     
         <param name="DEFAULT_FONT"           value="Arial">
    </applet>
    pass values @ ur html or jsp page to Applet as parameters.
    Refer above code. By using getParameter() method of Applet, u can take values inside applet.

Maybe you are looking for