Best practice for component layout?

Hi,can people tell me their views on best practice in this area, using JSF.
Eg, say I want this:
    LabelSml    InputField
    LabelLarge  InputField... ie 2 labels, 2 fields, vertically alligned, and with some space between the label and the field.
and this one:
    Field                             Field... ie 2 fields with a lot of space between them.
Finally, are there any examples on the web of UIs with many discrete fields on them (as opposed to logon/helloWorld and matrix data control), where I can look at how the design has been done.
Marc

I don't know if our solution is a best practice. We are not using the label property of input components because the alignment does not satisfy then. Instead we are using a <h:panelGrid> and nest <ui:label> and <ui:textField> (Studio Creator components) components in it. Multiple components in one cell are surrounded with a nested layout or grid panel. The number of columns is set by the attribute "columns" and width is controlled by the attribute "columnClasses". Example
<?xml version="1.0" encoding="UTF-8"?>
<jsp:root version="1.2" xmlns:bp="http://java.sun.com/blueprints/ui/14" xmlns:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html"
    xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:ui="http://www.sun.com/web/ui">
    <jsp:directive.page contentType="text/html;charset=UTF-8" pageEncoding="UTF-8"/>
    <f:view locale="#{SessionBean1.locale}">
        <f:loadBundle basename="com.asci.nef.resourcen.Aktionen" var="akt"/>
        <f:loadBundle basename="com.asci.nef.resourcen.Label" var="lab"/>
        <f:loadBundle basename="com.asci.nef.resourcen.Datenlisten" var="datenlisten"/>
        <f:loadBundle basename="com.asci.nef.resourcen.Meldungen" var="msg"/>
        <ui:page binding="#{personal$Mitarbeiterauswahl.page1}" id="page1">
            <ui:html binding="#{personal$Mitarbeiterauswahl.html1}" id="html1">
                <ui:head binding="#{personal$Mitarbeiterauswahl.head1}" id="head1">
                    <ui:link binding="#{personal$Mitarbeiterauswahl.link1}" id="link1" url="/resources/stylesheet.css"/>
                    <ui:script binding="#{personal$Mitarbeiterauswahl.scriptFenster}" id="scriptFenster" url="/resources/fenster.js"/>
                </ui:head>
                <ui:body binding="#{personal$Mitarbeiterauswahl.body1}" id="body1" style=" -rave-layout: grid">
                    <jsp:directive.include file="../Menue.jspf"/>
                    <ui:form binding="#{personal$Mitarbeiterauswahl.form1}" id="form1">
                        <div>
                            <jsp:directive.include file="../Fensterkennung.jspf"/>
                        </div>
                        <ui:tabSet binding="#{personal$Mitarbeiterauswahl.tabSetPersonaldaten}" id="tabSetPersonaldaten" selected="tabSuchen" style="position: absolute; left: 0px; top: 36px; width: 100%;">
                            <ui:tab binding="#{personal$Mitarbeiterauswahl.tabSuchen}" id="tabSuchen" text="#{akt.funktion110}">
                                <ui:panelLayout binding="#{personal$Mitarbeiterauswahl.layoutPanelSuchen}" id="layoutPanelSuchen">
                                    <h:panelGrid binding="#{personal$Mitarbeiterauswahl.gridPanelSuchen}" columnClasses="gridlabel, griddata" columns="2"
                                        id="gridPanelSuchen" style="position:absolute; left:100px; top:30px;">
                                        <ui:label binding="#{personal$Mitarbeiterauswahl.labelPersonalnummerSuchen}" id="labelPersonalnummerSuchen" text="#{lab.mitarbeiterauswahl_personalnummer}"/>
                                        <ui:textField binding="#{personal$Mitarbeiterauswahl.textFieldPersonalnummerSuchen}" converter="javax.faces.Long"
                                            id="textFieldPersonalnummerSuchen" maxLength="10" styleClass="eingabe1"/>
                                        <ui:label binding="#{personal$Mitarbeiterauswahl.labelNameSuchen}" for="textFieldNameSuchen" id="labelNameSuchen" text="#{lab.mitarbeiterauswahl_name}"/>
                                        <ui:textField binding="#{personal$Mitarbeiterauswahl.textFieldNameSuchen}" converter="TextTrim" id="textFieldNameSuchen"
                                            maxLength="30" styleClass="eingabe4"/>
                                        <ui:label binding="#{personal$Mitarbeiterauswahl.labelGeburtsdatumSuchen}" id="labelGeburtsdatumSuchen" text="#{lab.mitarbeiterauswahl_geburtsdatum}"/>
                                        <ui:textField binding="#{personal$Mitarbeiterauswahl.textFieldGeburtsdatumSuchen}"
                                            converter="#{SessionBean1.sqlDateConverter}" id="textFieldGeburtsdatumSuchen" maxLength="10" styleClass="eingabe1"/>
                                        <ui:label binding="#{personal$Mitarbeiterauswahl.labelTaetigkeitSuchen}" id="labelTaetigkeitSuchen" text="#{lab.mitarbeiterauswahl_taetigkeit}"/>
                                        <ui:dropDown binding="#{personal$Mitarbeiterauswahl.dropDownTaetigkeitSuchen}" id="dropDownTaetigkeitSuchen"
                                            items="#{personal$Mitarbeiterauswahl.listOptionsTaetigkeitSuchen}" styleClass="eingabe4"/>
                                        <ui:label binding="#{personal$Mitarbeiterauswahl.labelVereinbarungSuchen}" id="labelVereinbarungSuchen" text="#{lab.mitarbeiterauswahl_zusatzvereinbarung}"/>
                                        <ui:textField binding="#{personal$Mitarbeiterauswahl.textFieldVereinbarungSuchen}" id="textFieldVereinbarungSuchen" styleClass="eingabe4"/>
                                        <ui:label binding="#{personal$Mitarbeiterauswahl.labelSortieren}" id="labelSortieren" text="#{lab.mitarbeiterauswahl_sortieren}"/>
                                        <ui:radioButtonGroup binding="#{personal$Mitarbeiterauswahl.radioButtonGroupSortieren}" columns="4"
                                            id="radioButtonGroupSortieren"
                                            items="#{personal$Mitarbeiterauswahl.radioButtonGroupSortierenDefaultOptions.options}" required="true" selected="#{personal$Mitarbeiterauswahl.radioButtonGroupSortierenDefaultOptions.selectedValue}"/>
                                        <ui:label binding="#{personal$Mitarbeiterauswahl.labelDummy1}" id="labelDummy1"/>
                                        <ui:button action="#{personal$Mitarbeiterauswahl.buttonSuchen_action}"
                                            binding="#{personal$Mitarbeiterauswahl.buttonSuchen}" id="buttonSuchen" text="#{akt.button_suchen}"/>
                                        <ui:label binding="#{personal$Mitarbeiterauswahl.labelDummy2}" id="labelDummy2"/>
                                        <ui:listbox binding="#{personal$Mitarbeiterauswahl.listboxSuche}" id="listboxSuche" monospace="true"
                                            onDblClick="#{personal$Mitarbeiterauswahl.onDblClickAction}" rows="20" styleClass="eingabe7"/>
                                        <ui:label binding="#{personal$Mitarbeiterauswahl.labelDummy3}" id="labelDummy3"/>
                                        <ui:panelLayout binding="#{personal$Mitarbeiterauswahl.layoutPanelButtons2}" id="layoutPanelButtons2" panelLayout="flow">
                                            <ui:button action="#{personal$Mitarbeiterauswahl.buttonNeu_action}"
                                                binding="#{personal$Mitarbeiterauswahl.buttonNeu}" id="buttonNeu" immediate="true" text="#{akt.button_neu}"/>
                                            <ui:button action="#{personal$Mitarbeiterauswahl.buttonBearbeiten_action}"
                                                binding="#{personal$Mitarbeiterauswahl.buttonBearbeiten}" id="buttonBearbeiten" text="#{akt.button_bearbeiten}"/>
                                            <ui:button action="#{personal$Mitarbeiterauswahl.buttonLoeschen_action}"
                                                binding="#{personal$Mitarbeiterauswahl.buttonLoeschen}" id="buttonLoeschen" text="#{akt.button_loeschen}"/>
                                        </ui:panelLayout>
                                    </h:panelGrid>
                                </ui:panelLayout>
                            </ui:tab>
                        </ui:tabSet>
                        <h:panelGrid binding="#{personal$Mitarbeiterauswahl.gridPanelFehler}" id="gridPanelFehler" onclick="this.style.display = 'none';" style="position: absolute; right: 20px; bottom: 50px; width: 250px; height: 78px;"/>
                        <ui:panelLayout binding="#{personal$Mitarbeiterauswahl.layoutPanelConfirm}" id="layoutPanelConfirm" panelLayout="flow" style="position:absolute; top:36px; left:0px;width:100%; height:700px;">
                            <h:panelGrid binding="#{personal$Mitarbeiterauswahl.gridPanelConfirm}" columns="1" id="gridPanelConfirm" style="margin-left:auto; margin-right:auto; margin-top:300px; background-color:#FF3333;">
                                <ui:staticText binding="#{personal$Mitarbeiterauswahl.staticTextConfirm}" id="staticTextConfirm" text="#{msg.global_loeschen}"/>
                                <ui:panelLayout binding="#{personal$Mitarbeiterauswahl.layoutPanelConfirmButtons}" id="layoutPanelConfirmButtons" panelLayout="flow">
                                    <ui:button action="#{personal$Mitarbeiterauswahl.buttonConfirmYes_action}"
                                        binding="#{personal$Mitarbeiterauswahl.buttonConfirmYes}" id="buttonConfirmYes" text="#{akt.button_ja}"/>
                                    <ui:button action="#{personal$Mitarbeiterauswahl.buttonConfirmNo_action}"
                                        binding="#{personal$Mitarbeiterauswahl.buttonConfirmNo}" id="buttonConfirmNo" text="#{akt.button_nein}"/>
                                </ui:panelLayout>
                            </h:panelGrid>
                        </ui:panelLayout>
                    </ui:form>
                </ui:body>
            </ui:html>
        </ui:page>
    </f:view>
</jsp:root>

Similar Messages

  • Best Practices for image layout and positioning using anchored frames in Framemaker 10

    Hi,
    I'm looking for the best practices in how to layout my images in Framemaker 10 so that they translate correctly to Robohelp 9. I currently have images inside of Anchored frames that "Run into" the right side of my text. I've adjusted the size of the anchored frame so that my text flows correctly around the image. Everything looks good in Framemaker! Yeah! The problem is that when I link my Framemaker document to Robohelp, the text does not flow around my image in the same manner. On a couple of Robohelp screens the image is running into the footer. I'm wondering if I should be using tables in Framemaker in order to get the page layout that I'm looking for. Also, I went back and forth...is this a Framemaker question or is this a Robohelp question. Any assistance would be greatly appreciated.

    I wish I could offer some advice, rather than simply adding to your question. I think there is something odd that happens with anchored frames.
    I have been going through fits trying to figure out why the placement of my graphics shifts when I run them through Frame 10-to-RoboHelp 9 conversion. The placement in our books is flush left to the body text area. However, when they convert, some are flush left, some are centered, and a very few are flush right. My boss is very unhappy with me, as I have been unable to figure out why this is happening. I didn't create these files, so I don't know if it's something that goes back to how the graphics were initially imported. But I can't figure out why everything looks right in Framemaker, with the frame attached to an anchor tag, etc. but the placement goes hinky when they convert.
    Any insights are appreciated. I'm wondering if it's going to come down to deleting them and recreating the graphic frame.

  • Cairngorm 3 - Best practice for component states

    Hi,
    I have here small question.
    I have some component states (eq: application state, some component states, atp.) in my Application.
    I'm not sure if is best practise to save component states in Presentation Models, they hold current state only. So, i create ApplicationState class, which holding all possible application states. And here is my problem, i'm not sure, where should be this "State" class stored. In application directory or create another "states" directory  name ?
    Well, i'm not sure.
    Thx.

    Hi,
    I have here small question.
    I have some component states (eq: application state, some component states, atp.) in my Application.
    I'm not sure if is best practise to save component states in Presentation Models, they hold current state only. So, i create ApplicationState class, which holding all possible application states. And here is my problem, i'm not sure, where should be this "State" class stored. In application directory or create another "states" directory  name ?
    Well, i'm not sure.
    Thx.

  • What is best practice for conditional rendering?

    i have a set of radio buttons that conditionally render another set, which in turn conditionally render a 3rd set.
    i am doing this by using a valueChangeListener on an h:selectOneRadio
    when i click yes on the 1st set it renders the 2nd set.
    when i click yes on the 2nd set it renders the 3rd set.
    when i click no on the 1st set now it correctly removes the 2nd & 3rd sets, the method also nulls the values.
    when i click yes on the 1st set, it renders the 2nd set with the old values even though they were nulled. and i can see in the debugger they are still null.
    so there seems to be an issue updating the model, but i dont know what that issue is. im sure it just has something to do with the way i am trying this conditional render. please see below for my first field and my valueChangeListener method.
    any help with what is a best practice for this scenario would be greatly appreciated.
    <h:panelGrid id="grid20a" columns="1">
                             <h:outputText value="Does this consult pertain to a specific "/>
                             <h:outputText value="planned or ongoing research project?: *"/>
                        </h:panelGrid>
                        <h:selectOneRadio id="specificResearch1" value="#{ethicsConsultBacking.bean.specificResearch}"
                             layout="lineDirection" required="true"
                             valueChangeListener="#{ethicsConsultBacking.processValueChangeSpecificResearch}">
                                  <f:selectItems value="#{ethicsConsultBacking.yesNoMap}" />
                                  <a4j:support event="onclick" reRender="form"/>
                        </h:selectOneRadio>
                        <h:message for="specificResearch1" styleClass="redText" />
    public void processValueChangeSpecificResearch(ValueChangeEvent e) throws AbortProcessingException
              String newValue = e.getNewValue().toString();
              //reinitialize
              this.setRenderHumanSubjectResearch(false);
              this.setRenderIrbSection(false);
              this.setRenderIrbProtocolNumber(false);
              this.getBean().setHumanSubjectResearch(null);
              this.getBean().setPrimaryIrb(null);
              this.getBean().setIrbStatus(null);
              this.getBean().setIrbProtocolNumber(null);
              //check condition
              if (newValue.equalsIgnoreCase(this.YES))
                   this.setRenderHumanSubjectResearch(true);
               * Clearing validation messages.
               * This will get around the issue with having a field
               * on the form that is both required & immediate.
              Iterator it = this.getFacesContext().getMessages();
              while (it.hasNext())
                   it.next();
                   it.remove();
              this.getFacesContext().renderResponse();          
         }i also tried doing this another way by just using an action method attached to the a4j:support tag, but that introduced a different set of issue. so ill leave that out for now unless that is the direction someone would like to direct my issue in.
    Thanks in advance

    Similar issue is covered and explained here: [http://balusc.blogspot.com/2007/10/populate-child-menus.html]. Not sure if it solves your problem as you're using ajax4jsf whereas I don't, but it might give new insights. To the point you might need to bind the component(s) and use setValue(null) or setSubmittedValue(null).

  • Best practice for multi-language content in common areas

    I've got a site with some text in header/footer/nav that needs to be translated between an English and Spanish site, which use the same design. My intention was to set up all the text as content to facilitate. However, if I use a standard dialog with the component's path set to a child of the current page node, I would need to re-enter the text on every page. If I use a design dialog, or a standard dialog with the component's path set absolutely, the Engilsh and Spanish sites will share the same text. If I use a standard dialog with the component's path set relatively (eg path="../../jcr:content/myPath"), the pages using the component would all need to be at the same level of the hierarchy.
    It appears that the Geometrixx demo doesn't address this situation, and leaves copy in English. Is there a best practice for this scenario?

    I'm finding that something to the effect of <cq:include path="<%= strCommonContentPath + "codeEntry" %>" resourceType ...
    works fine for most components, but not for parsys, or a component containing a parsys. When I attempt that, I get a JS error that says "design.path is null or not an object". Is there a way around this?

  • Best Practice for utility in Sol Man 4.0

    We have software component ST-ICO of release 150_700 with Patch level 5
    We want a Template Selection for ‘Utility’ industry. I checked in
    the service market place and found that 'Baseline Package United
    Kingdom V1.50, Template: BP_BLKU150' is available in the above software
    component.
    But we are not getting any templates other than 'BP_UTUS147 - Best Practices for Water Utility' in the 'SOLAR_PROJECT_ADMIN'
    transaction.
    Kindly suggest any patch needs to be applied or some configuration need to be done.
    Regards
    Mani

    Hi Mani,
       Colud u plz give me the link of "where u find the template BP_BLKU150"?
    It will be helpful for me.
    Thanks
    Senthil

  • Best Practices for Defining NDS Java Projects...

    We are doing a Proof of Concept on using NDS to develop non-SAP Java applications.  We are attempting to determine if we can replace our current Java development tools with NDS/WAS.
    We are struggling with SAP's terminology and "plumbing" for setting up/defining Java projects.  For example, what is and when do you define Tracks, Software Components, Development Components, etc.  All of these terms are totally foreign to us and do not relate to our current Java environment (at least not that we can see).  We are also struggling with how the DTR and activities tie in to those components.
    If any one has defined best practices for setting up Java projects or has struggled with and overcome these same issues, please provide us with some guidance.  This is a very frustrating and time-consuming issue for us.
    Thank you!!

    Hi Peggy,
    In Component Model we divide software projects into small components.Components can use other components in well defined manner.
    A development object is a part of a component that can be changed or developed in some way; it provides the component with a certain part of its functionality. A development object may be a Java class, a Web Dynpro view, a table definition, a JSP page, and so on. Development objects are always stored as “sources” in a repository.
    A development component can be defined as a frame shared by a number of objects, which are part of the software.
    Software components combine components (DCs) to larger units for delivery and deployment.
    A track comprises configurations and runtime systems required for developing software component versions.It ensures stable states of deliverables used by subsequent tracks.
    The Design Time Repository is for versioning source code management. Distributed development of software in teams. Transport and replication of sources.
    You can also find lot of support in SDN for the above concepts with tutorials.
    Refer this Link for a overview on Java development Infrastructure(JDI)
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/webas/java/java development infrastructure jdi overview.pdf
    To understand further
    Working with Net Weaver Development Infrastructure :
    http://help.sap.com/saphelp_nw04/helpdata/en/03/f6bc3d42f46c33e10000000a11405a/content.htm
    In the above link you can find all the concepts clearly explained.You can also find the required tutorials for development.
    Regards,
    Vijith

  • What is the best practice for changing view states?

    I have a component with two Pie Charts that display
    percentages at two specific dates (think start and end values).
    But, I have three views: Start Value only, End Value only, or show
    Both. I am using a ToggleButtonBar to control the display. What is
    the best practice for changing this kind of view state? Right now
    (since this code was inherited), the view states are changed in an
    ActionScript function which sets the visible and includeInLayout
    properties on each Pie Chart based on the selectedIndex of the
    ToggleButtonBar, but, this just doesn't seem like the best way to
    do this - not very dynamic. I'd like to be able to change the state
    based on the name of the selectedItem, in case the order of the
    ToggleButtons changes, and since I am storing the name of the
    selectedItem for future reference.
    Would using States be better? If so, what would be the best
    way to implement this?
    Thanks.

    I would stick with non-states, as I have always heard that
    states are more for smaller components that need to change under
    certain conditions, like a login screen that changes if the user
    needs to register.
    That said, if the UI of what you are dealing with is not
    overly complex, and if it will not become overly complex, maybe
    states is the way to go.
    Looking at your code, I don't think you'll save much in terms
    of lines of code.

  • JSF - Best Practice For Using Managed Bean

    I want to discuss what is the best practice for managed bean usage, especially using session scope or request scope to build database driven pages
    ---- Session Bean ----
    - In the book Core Java Server Faces, the author mentioned that most of the cases session bean should be used, unless the processing is passed on to other handler. Since JSF can store the state on client side, i think storing everything in session is not a big memory concern. (can some expert confirm this is true?) Session objects are easy to manage and states can be shared across the pages. It can make programming easy.
    In the case of a page binded to a resultset, the bean usually helds a java.util.List object for the result, which is intialized in the constructor by query the database first. However, this approach has a problem: when user navigates to other page and comes back, the data is not refreshed. You can of course solve the problem by issuing query everytime in your getXXX method. But you need to be very careful that you don't bind this XXX property too many times. In the case of querying in getXXX, setXXX is also tricky as you don't have a member to set. You usually don't want to persist the resultset changes in the setXXX as the changes may not be final, in stead, you want to handle in the actionlistener (like a save(actionevent)).
    I would glad to see your thought on this.
    --- Request Bean ---
    request bean is initialized everytime a reuqest is made. It sometimes drove me nuts because JSF seems not to be every consistent in updating model values. Suppose you have a page showing parent-children a list of records from database, and you also allow user to change directly on the children. if I hbind the parent to a bean called #{Parent} and you bind the children to ADF table (value="#{Parent.children}" var="rowValue". If I set Parent as a request scope, the setChildren method is never called when I submit the form. Not sure if this is just for ADF or it is JSF problem. But if you change the bean to session scope, everything works fine.
    I believe JSF doesn't update the bindings for all component attributes. It only update the input component value binding. Some one please verify this is true.
    In many cases, i found request bean is very hard to work with if there are lots of updates. (I have lots of trouble with update the binding value for rendered attributes).
    However, request bean is working fine for read only pages and simple binded forms. It definitely frees up memory quicker than session bean.
    ----- any comments or opinions are welcome!!! ------

    I think it should be either Option 2 or Option 3.
    Option 2 would be necessary if the bean data depends on some request parameters.
    (Example: Getting customer bean for a particular customer id)
    Otherwise Option 3 seems the reasonable approach.
    But, I am also pondering on this issue. The above are just my initial thoughts.

  • Best practice for integrating oracle atg with external web service

    Hi All
    What is the best practice for integrating oracle atg with external web service? Is it using integration repository or calling the web service directly from the java class using a WS client?
    With Thanks & Regards
    Abhishek

    Using Integration Repository might cause performance overhead based on the operation you are doing, I have never used Integration Repository for 3rd Party integration therefore I am not able to make any comment on this.
    Calling directly as a Java Client is an easy approach and you can use ATG component framework to support that by making the endpoint, security credentials etc as configurable properties.
    Cheers
    R
    Edited by: Rajeev_R on Apr 29, 2013 3:49 AM

  • Best Practice for External Libraries Shared Libraries and Web Dynrpo

    Two blogs have been written on sharing libraries with Web Dynpro DC, but I would
    like to know the best practice for doing this.
    External libraries seem to work great at compile time, but when deploying there is often an error related to the external library not being a deployed component. 
    Is there a workaround for this besides creating a shared J2EE library which I have been able to get working?  I am not interested in something that works, but really
    what are the best practice for this. What is the best way to  limit the number of jars that need to be kept in a shared library/ext library.  When is sharing ref service/etc a valid approach vs. hunting down the jars in the portal libraries etc and storing in an external library.

    Security is mainly about mitigation rather than 100% secure, "We have unknown unknowns". The component needs to talk to SQL Server. You could continue to use http to talk to SQL Server, perhaps even get SOAP Transactions working but personally
    I'd have more worries about using such a 'less trodden' path since that is exactly the areas where more security problems are discovered. I don't know about your specific design issues so there might be even more ways to mitigate the risk but in general you're
    using a DMZ as a decent way to mitigate risk. I would recommend asking your security team what they'd deem acceptable.
    http://pauliom.wordpress.com

  • Best practice for external but secure access to internal data?

    We need external customers/vendors/partners to access some of our company data (view/add/edit).  It’s not so easy as to segment out those databases/tables/records from other existing (and put separate database(s) in the DMZ where our server is).  Our
    current solution is to have a 1433 hole from web server into our database server.  The user credentials are not in any sort of web.config but rather compiled in our DLLs, and that SQL login has read/write access to a very limited number of databases.
    Our security group says this is still not secure, but how else are we to do it?  Even if a web service, there still has to be a hole in somewhere.  Any standard best practice for this?
    Thanks.

    Security is mainly about mitigation rather than 100% secure, "We have unknown unknowns". The component needs to talk to SQL Server. You could continue to use http to talk to SQL Server, perhaps even get SOAP Transactions working but personally
    I'd have more worries about using such a 'less trodden' path since that is exactly the areas where more security problems are discovered. I don't know about your specific design issues so there might be even more ways to mitigate the risk but in general you're
    using a DMZ as a decent way to mitigate risk. I would recommend asking your security team what they'd deem acceptable.
    http://pauliom.wordpress.com

  • Best Practice for using multiple models

    Hi Buddies,
         Can u tell me the best practices for using multiple models in single WD application?
        Means --> I am using 3 RFCs on single application for my function. Each time i am importing that RFC model under
        WD --->Models and i did model binding seperately to Component Controller. Is this is the right way to impliment  multiple            models  in single application ?

    It very much depends on your design, but One RFC per model is definitely a no no.
    Refer to this document to understand how should you use the model in most efficient way.
    http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/705f2b2e-e77d-2b10-de8a-95f37f4c7022?quicklink=events&overridelayout=true
    Thanks
    Prashant

  • Best practice for mouseless ADF applications

    I am developing an ADF application where the users do not want to use the mouse.
    So I would like to know if there are a best practice for this?
    I am already using the accessKey functionality and subforms defaultCommand
    But I have had problems setting focus to objects on a page like tables. I would like a button to return the focus to the table after it has made the command like delete.
    I have implemented a solution where I have found inspiration several threads and other webpages (see below).
    Is this solution okay?
    Are there any problems with it?
    I would also like to know if there are better pathways to go like
    out of the box solutions,
    http://www.oracle.com/technetwork/developer-tools/adf/learnmore/79-global-template-button-strategy-360139.pdf (are there an example implementation?), or
    http://one-size-doesnt-fit-all.blogspot.dk/2010/11/adf-ui-shell-supporting-global-hotkeys.html
    in advance thanks
    Inspiration webpages
    https://blogs.oracle.com/jdevotnharvest/entry/how_to_programmatically_set_focus
    http://technology.amis.nl/2008/01/04/adf-11g-rich-faces-focus-on-field-after-button-press-or-ppr-including-javascript-in-ppr-response-and-clientlisteners-client-side-programming-in-adf-faces-rich-client-components-part-2/
    how to Commit table by writting Java code in Managed Bean?
    Table does not refresh and getting error as UIComponent is Null
    A short description of the solution:
    (jdeveloper version 11.1.1.2.0)
    --- Example where I use onSetFocus in jsff page
    <af:commandButton text="#{hrsusuiBundle.FOCUS}" id="cb10"
    partialSubmit="true" accessKey="f"
    shortDesc="Alt+Shift+F"
    actionListener="#{managedBean_clientUtils.onSetFocus}">
    <af:clientAttribute name="focusField" value="t1"/>
    </af:commandButton>
    --- Examples where I use doTableActionAndSetFocus in jsff page
    --- There have to be a binding in the jsff page to delete, commit and rollback
    <af:commandButton text="#{hrsusuiBundle.DELETE}" id="cb4"
    accessKey="x"
    shortDesc="Alt+Shift+X"
    partialSubmit="true"
    actionListener="#{managedBean_clientUtils.doTableActionAndSetFocus}">
    <af:clientAttribute name="focusField" value="t1"/>
    <af:clientAttribute name="actionField" value="Delete"/>
    </af:commandButton>
    <af:commandButton text="#{hrsusuiBundle.COMMIT}" id="cb5"
    accessKey="s" shortDesc="Alt+Shift+S"
    partialSubmit="true"
    actionListener="#{managedBean_clientUtils.doTableActionAndSetFocus}">
    <af:clientAttribute name="focusField" value="t1"/>
    <af:clientAttribute name="actionField" value="Commit"/>
    </af:commandButton>
    <af:commandButton text="#{hrsusuiBundle.ROLLBACK}" id="cb6"
    accessKey="z" shortDesc="Alt+Shift+Z"
    partialSubmit="true"
    actionListener="#{managedBean_clientUtils.doTableActionAndSetFocus}"
    immediate="true">
    <af:resetActionListener/>
    <af:clientAttribute name="focusField" value="t1"/>
    <af:clientAttribute name="actionField" value="Rollback"/>
    </af:commandButton>
    --- This is the java class I use
    --- It is published in adfc-config.xml as a request scope managedbean
    public class ClientUtils {
    public ClientUtils() {
    public void doTableActionAndSetFocus(ActionEvent event) {
    RichCommandButton rcb = (RichCommandButton)event.getSource();
    String focusOn = (String)rcb.getAttributes().get("focusField");
    String actionToDo = (String)rcb.getAttributes().get("actionField");
    UIComponent component = null;
    String clientId = null;
    component = JSFUtils.findComponentInRoot(focusOn);
    clientId = component.getClientId(JSFUtils.getFacesContext());
    if ( "Delete".equals(actionToDo) || "Commit".equals(actionToDo) || "Rollback".equals(actionToDo) ){
    BindingContainer bindings = BindingContext.getCurrent().getCurrentBindingsEntry();
    OperationBinding operationBinding = bindings.getOperationBinding(actionToDo);
    Object result = operationBinding.execute();
    AdfFacesContext.getCurrentInstance().addPartialTarget(component);
    if (clientId != null) {           
    makeSetFocusJavaScript(clientId);
    public static String onSetFocus(ActionEvent event) {
    RichCommandButton rcb = (RichCommandButton)event.getSource();
    String focusOn = (String)rcb.getAttributes().get("focusField");
    String clientId = null;
    if (focusOn.contains(":")) {
    clientId = focusOn;
    } else {
    clientId = findComponentsClientIdInRoot(focusOn);
    if (clientId != null) {           
    makeSetFocusJavaScript(clientId);
    return null;
    private static void writeJavaScriptToClient(String script) {
    FacesContext fctx = FacesContext.getCurrentInstance();
    ExtendedRenderKitService erks = null;
    erks = Service.getRenderKitService(fctx, ExtendedRenderKitService.class);
    erks.addScript(fctx, script);
    public static void makeSetFocusJavaScript(String clientId) {
    if (clientId != null) {
    StringBuilder script = new StringBuilder();
    //use client id to ensure component is found if located in
    //naming container
    script.append("var textInput = ");
    script.append("AdfPage.PAGE.findComponentByAbsoluteId");
    script.append ("('"+clientId+"');");
    script.append("if(textInput != null){");
    script.append("textInput.focus();");
    script.append("}");
    writeJavaScriptToClient(script.toString());
    public static String findComponentsClientIdInRoot(String id) {
    UIComponent component = null;
    String clientId = null;
    component = JSFUtils.findComponentInRoot(id);
    clientId = component.getClientId(JSFUtils.getFacesContext());
    return clientId;
    }

    Hi,
    I am developing an ADF application where the users do not want to use the mouse. So I would like to know if there are a best practice for this?
    Well HTML (and this is the user interface you see) follows a tab index navigation that you follow with "tab" and "shift+tab". Anything else is a short cut for which you use mnemonics (as you already do) or shortcuts (explained in http://one-size-doesnt-fit-all.blogspot.dk/2010/11/adf-ui-shell-supporting-global-hotkeys.html). There is a distinction to make between non-web environments (which I think you and your users have abackground in) and client desktop environments. Browsers block some keyboard functionality for their own purpose. So you may have to find a list of keys first that work across browsers. Unlike desktop clients, which allow you to "press a button" without the button to take focus, this cannot be done on the web. So you need to be clever here, avoiding buttons at all.
    The following paper is about JavaScript in ADF and explains the basics for what Chris Muir explains in : http://one-size-doesnt-fit-all.blogspot.dk/2010/11/adf-ui-shell-supporting-global-hotkeys.html
    http://www.oracle.com/technetwork/developer-tools/jdev/1-2011-javascript-302460.pdf
    It has the outline for how to register short cut keys that perform a specific action (e.g. register ctrl+d to delete the current row you are on, or press F11 to execute a query (similar to Oracle Forms frmres files)). However, be aware that this includes some code you have to write (actually quite some code to be honest).
    http://www.oracle.com/technetwork/developer-tools/adf/learnmore/79-global-template-button-strategy-360139.pdf (are there an example implementation?), or
    http://one-size-doesnt-fit-all.blogspot.dk/2010/11/adf-ui-shell-supporting-global-hotkeys.html
    Actually these are implementations as they come with example code for you to use and customize, do they? So what is this question asking for more ? Also note that global buttons don't quite have anything in common with the question you asked. I assume you want to see it as an implementation of the Forms toolbar that operates on the form or table the focus is in. This however does not work for the web as there is nothing that keeps track of which component has a focus and to what iterator (data block) it belongs. This would involve even more coding (though possibly doable)
    Frank

  • What are best practice for packaging and deploying j2EE apps to iAS?

    We've been running a set of J2EE applications on a pair of iAS SP1b for about a year and it has been quite stable.
    Recently however we have had a number of LDAP issues, particularly when registering and unregistering applications (registering ear files sometimes fails 1st time but may work 2nd time). Also We've noticed very occasionally that old versions of classes sometimes find their way onto our machines.
    What is considered to be best practice in terms of packaging and deployment, specifically:
    1) Packaging - using the deployTool that comes with iAS6 SP1b to package is a big manual task, especially when you have 200+ jsp files. Are people out there using this or are they scripting it with a build tool such as Ant?
    2) Deploying an existing application to multiple iAS's. Are you guys unregistering old application then reregistering new application? Are you shutting down iAS whilst doing the deployment?
    3) Deploying ear files can take 5 to 10 mins, is this normal?
    4) In a clustered scenario where HTTPSession is shared what are the consequences of doing deployments to data stored in session?
    thanks in asvance for your replies
    Owen

    You may want to consider upgrading your application server environment to a newer service pack. There are numerous enhancements involving the deployment tool and run time layout of your application that make clear where you're application is loading its files from.
    If you've at a long running application server environment, with lots of deployments under your belt, you might start to notice slow downs in deployment and kjs start time. Generally this is due to garbage collecting in your iAS registry.
    You can do several things to resolve this. The most complete solution is to reinstall the application server. This will guarantee a clean ldap registry. Of course you've got to restablish your configurations and redeploy your applications. When done, backup your application server install space with the application server and directory server off. You can use this backup to return to a known configuation at some future time.
    For the second method: <B>BE CAREFUL - BACKUP FIRST</B>
    There is a more exhaustive solution that involves examining your deployed components to determine the active GUIDS. You then search the NameTrans section of the registry searching for Applogic Servlet *, and Bean * entries that represent your previously deployed components but are represented in the set of deployed GUIDs. Record these older GUIDs, remove them from ClassImp and ClassDef. Finally remove the older entries from NameTrans.
    Best practices for deployment depend on your particular environmental needs. Many people utilize ANT as a build tool. In later versions of the application server, complete ANT scripts are included that address compiling, assembly and deployment. Ant 1.4 includes iAS specific targets and general J2EE targets. There are iAS specific targets that can be utilized with the 1.3 version. Specialized build targets are not required however to deploy to iAS.
    Newer versions of the deployment tool allow you to specify that JSPs are not to be registered automatically. This can be significant if deployment times lag. Registered JSP's however benefit more fully from the services that iAS offers.
    2) In general it is better to undeploy then redeploy. However, if you know that you're not changing GUIDs, recreating an existing application with new GUIDs, or removing registered components, you may avoid the undeploy phase.
    If you shut down the KJS processes during deployment you can eliminate some addition workload on the LDAP server which really gets pounded during deployment. This is because the KJS processes detect changes and do registry loads to repopulate their caches. This can happen many times during a deployment and does not provide any benefit.
    3) Deploying can be a lengthy process. There have been improvements in that performance from service pack to service pack but unfortunately you wont see dramatic drops in deployment times.
    One thing you can do to reduce deployment times is to understand the type of deployment. If you have not manipulated your deployment descriptors in any way, then there is no need to deploy. Simply drop your newer bits in to the run time space of the application server. In later service packs this means exploding the package (ear,war, or jar) in to the appropriate subdirectory of the APPS directory.
    4) If you've changed the classes of objects that have been placed in HTTPSession, you may find that you can no longer utilize those objects. For that reason, it is suggested that objects placed in session be kept as simple as possible in order to minimize this effect. In general however, is not a good idea to change a web application during the life span of a session.

Maybe you are looking for

  • Variable entry warning with RRMS_MESSAGE_HANDLING

    Hi, If I post a message in the Variable Exit (I_STEP = 3) with the function module RRMS_MESSAGE_HANDLING, the user cannot execute the variable until a valid entry exists. I would like to only raise an information that appears only once and the user c

  • Foreign language emails

    Hi all, For my work, I receive some emails that are written in Spanish. I used to be able to see them fine. Then recently the special characters are no longer displayed and now emails from certain senders (all from abroad) are displayed in a string o

  • TIP 02: Easy Connect Naming Method in 10g by Joel Pèrez

    Hi OTN Readers! Everyday I get connection on Internet and one of the first issues that I do is to open the OTN main page to look for any new article or any new news about the Oracle Technology. After I open the main page of OTN Forums and I check wha

  • Subtracting/adding Business days

    Hi everyone ! I have a calendar question: I have a date, number of days (either business or calendar) and Before/After indicator. I need to calculate the future/past date depending on business/calendar nn days. Ideally, I will also read Holidays tabl

  • Missed elements

    Why does acrobat X sometimes miss out elements when I print from a word 2010 document.  I have just printed a document for a client and there are whole text boxes missing from the pdf file.  Anyone else have this experience? How do I get it to print