Show hint in a ImageIcon

Is there any way to put in a ImageIcon a hint to specify the utility of the button?
Example:
http://156.35.94.1/~i2619734/jgraph/hint.JPG
There is a method called set/getDescription, but I put the description and I don't know how to show it how a hint.
In GraphEd I think It would a good idea.

URL insertUrl = getClass().getClassLoader().getResource("resources/insert.gif");
ImageIcon insertIcon = new ImageIcon(insertUrl);
// Lets get the button created by toolbar
JButton myButton = toolbar.add(new AbstractAction("", insertIcon) {
    public void actionPerformed(ActionEvent e) {
        insert(new Point(10, 10));
// Lets set it a tooltip text
myButton.setToolTipText("This is a tooltip !!");if you want to remove the tooltip, set it to null.
you can also put HTML in your tooltip :
myButton.setToolTipText("<html>This is a <b>HTML</b> <i>tooltip</i> !!</html>");hope it helps
Nico

Similar Messages

  • Contact form, how to hide text and show hints?

    I want to create a contact form, using Dreamweaver. In the preview it looks allright. But when uploading, I get the following problems:
    The "hints" inside the boxes are missing, nomatter what browser I use.
    The text "A value is required" (for example) is visible all the time. It should only be visible if people enter and leave the box blank.
    And I just saw that it doesn't respect my font either, only in the preview mode.
    Preview:
    Uploaded (bad!):
    <form id="form1" name="form1" method="post" action="formmail.php">
      <span id="nameTextField">
      <label for="name">Name</label> <br />
      <input type="text" name="name" id="name" tabindex="10" />
      <span class="textfieldRequiredMsg">A value is required.</span></span>
      <p><span id="emailTextField">
      <label for="email">Email</label><br />
      <input type="text" name="email" id="email" tabindex="20" />
      <span class="textfieldRequiredMsg">A value is required.</span><span class="textfieldInvalidFormatMsg">Invalid format.</span></span></p>
      <p><span id="messageTextArea">
      <label for="message">Message</label> <br />
      <textarea name="message" id="message" cols="75" rows="8" tabindex="30"></textarea>
      <span id="countmessageTextArea"> </span><span class="textareaRequiredMsg">A value is required.</span><span class="textareaMinCharsMsg">Minimum number of characters not met.</span><span class="textareaMaxCharsMsg">Exceeded maximum number of <br />
      characters.</span></span></p>
      <label for="submit"></label>
      <input type="submit" name="submit" id="submit" value="Submit" tabindex="40" />
    </form>
    <script type="text/javascript">
    <!--
    var sprytextfield1 = new Spry.Widget.ValidationTextField("nameTextField", "none", {validateOn:["blur"], hint:"Your name"});
    var sprytextfield2 = new Spry.Widget.ValidationTextField("emailTextField", "email", {hint:"Your email", validateOn:["blur"]});
    var sprytextarea1 = new Spry.Widget.ValidationTextarea("messageTextArea", {minChars:1, maxChars:999, counterType:"chars_remaining", counterId:"countmessageTextArea", validateOn:["blur"], hint:"Your message"});
    //-->
    </script>

    Did you upload your Spry assets folder and CSS files to your remote server?
    Can you provide a link to your problem page?
    Nancy O.

  • Stacked Bar showing VALUE literal instead of X axis value in hover hint

    I am converting to APEX 3.0 and noticed that the new "Show Hint" doesnt display the X axis value on a Stacked bar. Instead it shows the literal "VALUE". For example, I am displaying the number of orders for a given day. X=date, Y = count. I was expecting the Hint to display "11/15/07, 15" but instead it displays "VALUE, 15".
    This same sql displays correctly when I use it in a Line Chart.
    Any ideas? Thank You

    Bump...having same issue, still scanning message board for solution.

  • Display Hint Text in Oracle Forms 6i at Text Item

    Dear all seniors
    I want to show Hint text at Text Item in Oracle Forms 6i.
    when my cursor Focus goes at that item. I mean when I go with Tab key or Enter button then it show display text.
    even though my mouse is not on that item.
    please how it would be possible
    thanks.
    G.Y

    Please create a display_item(for eg. Disp_Mess) just below the text field (For eg:-MyField) where you want to show hint. And then assighn Hint text to "DISP_MESS" in NEW-FORM-INSTANCE or at Initial value. Then create a PRE-TEXT-ITEM and POST-TEXT-ITEM trigger for MyField.
    -- PRE-TEXT-ITEM trigger write following code.
    SET_ITEM_PROPERTY('DISP_MESS',VISIBLE,PROPERTY_TRUE);
    --POST-TEXT-ITEM write following code.
    SET_ITEM_PROPERTY('DISP_MESS',VISIBLE,PROPERTY_FALSE);
    It will work for you.
    Regards
    Ahamed Rafeeque Cherkala

  • How to show popup from backing bean code immediately?

    Hi,
    I'm using JDeveloper 11.1.2.1.0 and have problems with showing popups. I have a button with an action on my page and a method in backing bean.
    I want to rise up few popups from this method in backing bean (for example just an anouncement that something will happen) or a dialog
    (for example a question if you want to continue).
    I understand how to get a dialog response to deal with it in code, but the problem is that the popup doesn't show up immediately, but only when
    this method called on button finishes. I'd like to handle dialog responses in the middle of the action and then the code to continue with the execution.
    Here is my backing bean code:
    private RichPopup popup;
    public String test() {
    //Some code...
    RichPopup.PopupHints hints = new RichPopup.PopupHints();
    popup.show(hints);
    //Here is the place for code which I want to be executed after popup closes,
    //but is executed before the popup shows...
    return null;
    And here is part of my jssf:
    <af:commandButton text="Test" id="cb1"
    action="#{popupBean.test}"/>
    <af:popup id="popup" binding="#{popupBean.popup}">
    <af:dialog id="dialog" type="yesNo"
    title="Dialog"
    dialogListener="#{popupBean.onDialogAction}"
    binding="#{popupBean.dialog}" clientComponent="true">
    <af:outputText value="Do you want to continue?" id="ot1"/>
    <af:clientListener method="onDialogCancel" type="dialog"/>
    <af:serverListener type="DialogCancelHandlerEvent" method="#{popupBean.onDialogCancel}"/>
    </af:dialog>
    </af:popup>
    Can someone give me some answer how to show the popup from backing bean code immediately?
    Thanks in advance,
    Tina

    If you want to execute code after popup closes, then put this code in PopupCanceledListener or in DialogListener(you can't block method execution).
    Dario

  • Popup in JSFF not showing

    I have some code that I was testing in a separate application until I got it working. Essentially, I have a horizontally scrollable image list. When clicking on the image, a dynamically constructed popup menu shows up and when selecting a menu item, data is inserted based on the menu item clicked on. This worked when I had all my code in a JSPX. The popup was in a form.
    However, in our real application, we use fragments. So I put the popup in the JSFF where the image list is just under the jsp:root. I got this warning that says: "Fragment with more than one root component may not display correctly in a region."
    When I click on my image, the action listener fires and everything seems to be fine except that the popup does not show up. This is the method I call to show the popup:
         * Opens the RichPopup based on the key.
         * @param popupId - component ID of popup
         * @param alignId - component ID of component to align to
        public static void showPopup(String popupId, String alignId) {
            FacesContext context = FacesContext.getCurrentInstance();
            StringBuilder script = new StringBuilder();
            script.append("var popup = AdfPage.PAGE.findComponent('").append(popupId).append("'); ").append("if (!popup.isPopupVisible()) { ")
                .append("var hints = {}; ").append("hints[AdfRichPopup.HINT_ALIGN_ID] = '").append(alignId).append("'; ")
                .append("hints[AdfRichPopup.HINT_ALIGN] = AdfRichPopup.ALIGN_AFTER_END; ").append("popup.show(hints);}");
            ExtendedRenderKitService erks = Service.getService(context.getRenderKit(), ExtendedRenderKitService.class);
            erks.addScript(context, script.toString());
        }This worked fine in the JSPX version. So I'm wondering if there's something I need to do to get this to work. I should be able to have an inline popup in a JSFF, right? Is there a specific place where I'm supposed to put it?
    Here's JSFF:
    <?xml version='1.0' encoding='UTF-8'?>
    <jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="2.1" xmlns:af="http://xmlns.oracle.com/adf/faces/rich"
              xmlns:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html">
      <af:panelTabbed id="pt2">
      </af:panelTabbed>
      <af:popup id="vmenu" clientComponent="true">
        <af:menu text="menu 1" id="m2" binding="#{pageFlowScope.mainPageFlowBean.serviceMenu}"></af:menu>
      </af:popup>
    </jsp:root>I can put more detailed code if need be.
    Thanks.

    Eric,
    the problem seems to be that you don't find the popup using AdfPage.PAGE.findComponent(...) with your ID. Have you checked that you indeed get the popup using this function?
    Read [http://download.oracle.com/docs/cd/E12839_01/web.1111/b31973/af_arch.htm#insertedID5|http://download.oracle.com/docs/cd/E12839_01/web.1111/b31973/af_arch.htm#insertedID5] this, if you find out that you don't get the popup.
    Timo

  • Which is better for drawing JPGs on JLabel: ImageIcon or directly?

    I'm currently using this everywhere.
    BufferedImage bi;
    Jlabel jLabel;
    ImageIcon img = new ImageIcon( bi );
    jLabel.setIcon(imgIcon);but now I've discovered I can write images directly to the component from paintComponent( Graphics g )
    (from a subclass of JLabel)
    public void paintComponent( Graphics g ) {
      super.paintComponent( g );
      Graphics2D g2 = (Graphics2D)g;
      BufferedImage bi=getBufImg();
      g2.drawImage(bi, 0, 0, this.getWidth(), this.getHeight(), null );Is this more efficient or better form? Should I update my code everywhere?
    Also, the latter method seems to work the first time I call it, but I can't seem to change the image on an event like mouseEnter using code like this:
    public void mouseEntered(MouseEvent e) {
      Graphics g = this.getGraphics();
      Graphics2D g2 = (Graphics2D)g;
      BufferedImage bi=getBufImg();
      g2.drawImage(bi, 0, 0, this.getWidth(), this.getHeight(), null );
    }what's wrong?

    Is this more efficient or better form?
    No.
    Should I update my code everywhere?
    It depends on what you want to do. If you want to show an image then ImageIcon is an easy way. Override paintComponent when you want to do something other than simply display the image, eg, write text on top of the image or alter the image with things like rotation and scaling.
    Also, the latter method seems to work the first time I call it, but I can't seem to change the image on an event like mouseEnter using code like this
    Don't put painting code inside event code. Painting/drawing code belongs in an appropriate painting method. Use member variables in the enclosing class for state, manipulate these from your event code and set up your painting method to be able to accurately render this state at any time.
    stephensk8s is correct about the mouseEntered method. It works for components. So using a simple JLabel with ImageIcon is a carefree way to achieve rollover affects.
    Creating this kind of thing for custom graphics and images takes a little more effort. It all depends on what you are trying to do.
    Is there a good place to go to get a better understanding of this, or just ask on this forum?
    Ask when you need help.
    Resources that may be helpful to get started:
    Lesson: Writing Event Listeners
    Lesson: Performing Custom Painting
    How to Use Icons
    Lesson: Working with Images
    Core Java Technologies Tech Tips.

  • Map Chart in APEX 4.0 doesn't show data

    Code::::
    select null link,
    state label,
    count(contact_id) value
    from contacts
    group by state
    I have the states entered into the table in full names not abreviations yet no data shows up on the map not even when I click on a state
    According to the following website:
    http://www.oracle.com/webfolder/technetwork/tutorials/obe/db/apex/r40/apexcharts/apexcharts_ll.htm
    under the Creating a Map Chart section, step #8 it shows a checkbox to indicate to "Show Values". In my version of APEX 4.0.2.00.07 I only have a checkbox for "Show Hints" and "Show Label"
    Am I missing something that has to be installed to make this map chart work? Is this a bug that needs a patch? I believe I am at the higest patch for APEX.

    I answered my own question. Apparently the state cannot be entered into the database in all caps. Once I changed the First letter to caps and all the rest lower case the data showed up on my map

  • Pop up not showing when not file found

    I have a page where i download some files:
    <af:form id="f1" usesUpload="true">
    <af:popup id="pDoc" binding="#{pageFlowScope.GestionDocumentos.pdoc}">
    <af:dialog id="dMes" title="Mensaje" type="none">
    <af:outputText id="otMes" value="Archivo no encontrado"
    binding="#{pageFlowScope.GestionDocumentos.dlgDoc}"/>
    </af:dialog>
    </af:popup>
    <af:column id="cDes" headerText="Descargar"
    sortable="false" align="center" width="50">
    <af:commandImageLink id="gilDes" text="descargar"
    partialSubmit="true">
    <af:setPropertyListener from="#{row.Gesdopcrut}"
    to="#{pageFlowScope.GestionDocumentos.rutAch}"
    type="action"/>
    <af:fileDownloadActionListener filename="#{row.Gesdopcach}"
    method="#{pageFlowScope.GestionDocumentos.descargarArchivo}"/>
    </af:commandImageLink>
    </af:column>
    My backing Bean:
    public void descargarArchivo(FacesContext context, OutputStream out) {
    FileInputStream f = null;
    try {
    f = new FileInputStream("//"+ Constants.SERVIDOR_FTP_DEFAULT + rutAch);
    } catch (FileNotFoundException e) {
    RichPopup.PopupHints hints = new RichPopup.PopupHints();
    hints.add(RichPopup.PopupHints.HintTypes.HINT_ALIGN,
    RichPopup.PopupHints.AlignTypes.ALIGN_END_BEFORE);
    pdoc.show(hints);
    try {
    out.flush();
    out.close();
    } catch (IOException g) {
    g.printStackTrace();
    context.responseComplete();
    if (f != null) {
    byte[] buf = new byte[1024];
    try {
    while (f.available() > 0) {
    out.write(buf, 0, f.read(buf));
    f.close();
    out.flush();
    out.close();
    } catch (IOException e) {
    e.printStackTrace();
    I want to show the popup showing a message when the file is not found in the directory. But it is not showing , even though the FileInputStream is null, the download dialog opens and creates a new file of whatever type in blank.
    Also for now i m just simulating the file is in a ftp server for creatin the FileInputStream.

    check at
    Re: Popup not opening due to full apge submit
    Re: Show Popup From Managed Bean

  • Showing af:popup from bean - the new way?

    I've been using this approach in my bean, to show a popup:
    My bean:
    +try {+
    FacesContext context = FacesContext.getCurrentInstance();
    +if (popupId != null) {+
    StringBuilder script = new StringBuilder();
    script.append("var popup = AdfPage.PAGE.findComponent('").append(popupId).append("'); ");
    +script.append("if (!popup.isPopupVisible()) { ").append("popup.show();}");+
    +ExtendedRenderKitService erks =+
    +Service.getService(context.getRenderKit(),+
    +ExtendedRenderKitService.class);+
    +erks.addScript(context, script.toString());+
    +}+
    However; I've read that in ADF 11g it should be possible to just access the binded element. Like this +myPopup.show+
    If I use the later approach, my popup collapses to a little square in the upper left corner. If I use the javascript approach everything works fine.
    *My jspx:*
    +<af:popup id="found_none_popup" contentDelivery="lazyUncached"+
    +binding="#{backingBeanScope.backing_view1.popup1}">+
    +<af:dialog title="none" contentHeight="200" contentWidth="200"+
    +id="dialog2"+
    +binding="#{backingBeanScope.backing_view1.dialog1}"+
    +type="none">+
    +<f:facet name="buttonBar">+
    +<af:group binding="#{backingBeanScope.backing_view1.g1}" id="g1">+
    +<af:panelGroupLayout binding="#{backingBeanScope.backing_view1.pgl1}"+
    +id="pgl1">+
    +<af:commandButton text="Annuller"+
    +binding="#{backingBeanScope.backing_view1.cb3}"+
    +id="cb3"/>+
    +<af:commandButton text="Opret Ny"+
    +binding="#{backingBeanScope.backing_view1.cb1}"+
    +id="cb1"/>+
    +</af:panelGroupLayout>+
    +</af:group>+
    +</f:facet>+
    +<af:panelGroupLayout binding="#{backingBeanScope.backing_view1.pgl2}"+
    +id="pgl2" layout="vertical">+
    +<af:outputText value="MXXXXXXXXXXUPS" id="ot5"/>+
    +<af:spacer width="10" height="10"+
    +binding="#{backingBeanScope.backing_view1.s1}"+
    +id="s1"/>+
    +<af:outputText value="HelleYYYYYYYYYY fundet."+
    +id="ot6"/>+
    +</af:panelGroupLayout>+
    +</af:dialog>+
    +</af:popup>+
    Any suggestions will be highly appreciated.

    Hi,
    Are you trying in this way...?
            RichPopup.PopupHints hints = new RichPopup.PopupHints();
            hints.add(RichPopup.PopupHints.HintTypes.HINT_ALIGN_ID, source)
                .add(RichPopup.PopupHints.HintTypes.HINT_LAUNCH_ID, source)
                .add(RichPopup.PopupHints.HintTypes.HINT_ALIGN,
                     RichPopup.PopupHints.AlignTypes.ALIGN_END_AFTER);
            popup1.show(hints);
    AdfFacesContext.getCurrentInstance().addPartialTarget(popup1);Regards,

  • Append hint generating huge redo

    Hi all,
    Sorry if this question was already asked here.
    We have few [partitioned] tables created with no logging option. Java code [which inserts data in these tables] has /*+ Append */ hint.
    DB is 10.2.0.5 version, DB is in archive.
    When we query "sys.v_$sqlarea" and "dba_users", we do see append hint for the insert statements. But when we do log mining we don’t see append hint there, all the insert statements [huge] are making into redo log[which we don’t want], Any idea why…?
    Thanks,
    AJ

    Thanks for your replies -
    Here is my insert hint -
    INSERT /*+ Append */ INTO tab_1(SUBTYPE........
    Let me know if hint is wrong?
    Question –
    sys.v_$sqlarea shows above hint but mined redo log [archived log as well] doesn’t show hint i.e. insert statement is shown like - INSERT INTO tab_1(SUBTYPE........
    Does that mean oracle is ignoring hint [because hint is wrong, what would be the correct hint]…?
    FYI – we have cursor_sharing set to similar – will that cause an issue?
    Thanks,
    AJ.

  • How to show button at the end of slide

    Hi,
    Two new problems below:
    1. How can I show my own button ("next") - that will take to the next slide - around 2 seconds before the end of each slide and after click I will be moved to the next slide.  My button is displayed for the rest of project and slides have different duration.
    2. How can I prevent student from moving playbar button face fast forward? I know I can hide playbar, but I do not want to do this way. I want playbar button face visible, but I want to deactivate playbar forward function.  Is there any solution for that?
    Thanks,
    Pawel

    Hi,
    I will try explain what I need:
    1. I need playbar and I have.
    2. I need button to glow on to show students how far they are and I have.
    3. I do not want students to move forward this button on playbar. I need this button to be uncontrollable by the students. So playbar will be just for information only.
    4. I need button next that will appear at the end of slide. If I have 20 slides I need to put 20 next buttons. Because I would like to speed up my work I try to create this button on first page and then use it on every slide for the rest of project. It will show at the end of each slide for example 2 seconds before or at the end. Now I used action on entry/exit and it works, but every slide I have to configure (on entry, on exit) separatley.
    5. I need to show hints to buttons on every slide. Now I have only on first slide, because my buttons come from smart shape (I set timing for the rest of project).
    Any Idea on making playbar button uncontrollable, showing hints on every slide for buttons, and button next?
    Thanks,
    Pawel

  • My macbook pro only shows apple logo and spinning wheel

    guys i forgot my macbook pro admin password i tried to give it a certain password but all set incorrect then it start showing hint but that also not worked then i tried shuting it down but the opyions below password column dint responded then i force shut downed it after that i us showing only apple logo and that spinng wheel for unlimited time.then i reseted the password by those command lines but it still giving the same response.
    can anyone help me out please....

    Take each of these steps that you haven't already tried. Stop when the problem is resolved.
    Step 1
    The first step in dealing with a boot failure is to secure your data. If you want to preserve the contents of the startup drive, and you don't already have at least one current backup, you must try to back up now, before you do anything else. It may or may not be possible. If you don't care about the data that has changed since your last backup, you can skip this step.   
    There are several ways to back up a Mac that is unable to boot. You need an external hard drive to hold the backup data.
         a. Boot into the Recovery partition, or from a local Time Machine backup volume (option key at startup.) When the OS X Utilities screen appears, launch Disk Utility and follow the instructions in this support article, under “Instructions for backing up to an external hard disk via Disk Utility.”
    b. If you have access to a working Mac, and both it and the non-working Mac have FireWire or Thunderbolt ports, boot the non-working Mac in target disk mode. Use the working Mac to copy the data to another drive. This technique won't work with USB, Ethernet, Wi-Fi, or Bluetooth.
    c. If the internal drive of the non-working Mac is user-replaceable, remove it and mount it in an external enclosure or drive dock. Use another Mac to copy the data.
    Step 2
    If the startup process stops at a blank gray screen with no Apple logo or spinning "daisy wheel," then the startup volume may be full. If you had previously seen warnings of low disk space, this is almost certainly the case. The easiest way to deal with the problem is to boot from an external drive, or else to use either of the techniques in Steps 1b and 1c to mount the internal drive and delete some files. According to Apple documentation, you need at least 9 GB of available space on the startup volume (as shown in the Finder Info window) for normal operation.
    Step 3
    Sometimes a boot failure can be resolved by resetting the NVRAM.
    Step 4
    If you use a wireless keyboard, trackpad, or mouse, replace or recharge the batteries. The battery level shown in the Bluetooth menu item may not be accurate.
    Step 5
    If there's a built-in optical drive, a disc may be stuck in it. Follow these instructions to eject it.
    Step 6
    Press and hold the power button until the power shuts off. Disconnect all wired peripherals except those needed to boot, and remove all aftermarket expansion cards. Use a different keyboard and/or mouse, if those devices are wired. If you can boot now, one of the devices you disconnected, or a combination of them, is causing the problem. Finding out which one is a process of elimination.
    Step 7
    If you've booted from an external storage device, make sure that your internal boot volume is selected in the Startup Disk pane of System Preferences.
    Boot in safe mode. Note: If FileVault is enabled, or if a firmware password is set, or if the boot volume is a software RAID, you can’t do this. Post for further instructions.
    Safe mode is much slower to boot and run than normal, and some things won’t work at all, including wireless networking on certain Macs.
    The login screen appears even if you usually log in automatically. You must know your login password in order to log in. If you’ve forgotten the password, you will need to reset it before you begin.
    When you boot in safe mode, it's normal to see a dark gray progress bar on a light gray background. If the progress bar gets stuck for more than a few minutes, or if the system shuts down automatically while the progress bar is displayed, your boot volume is corrupt and the drive is probably malfunctioning. In that case, go to Step 6.
    If you can boot and log in now, empty the Trash, and then open the Finder Info window on your boot volume ("Macintosh HD," unless you gave it a different name.) Check that you have at least 9 GB of available space, as shown in the window. If you don't, copy as many files as necessary to another volume (not another folder on the same volume) and delete the originals. Deletion isn't complete until you empty the Trash again. Do this until the available space is more than 9 GB. Then reboot as usual (i.e., not in safe mode.)
    If the boot process hangs again, the problem is likely caused by a third-party system modification that you installed. Post for further instructions.
    Step 8
    Launch Disk Utility in Recovery mode (see Step 1.) Select your startup volume, then run Repair Disk. If any problems are found, repeat until clear. If Disk Utility reports that the volume can't be repaired, the drive has malfunctioned and should be replaced. You might choose to tolerate one such malfunction in the life of the drive. In that case, erase the volume and restore from a backup. If the same thing ever happens again, replace the drive immediately.
    This is one of the rare situations in which you should also run Repair Permissions, ignoring the false warnings it may produce. Look for the line "Permissions repair complete" at the end of the output. Then reboot as usual.
    Step 9
    Reinstall the OS. If your Mac was upgraded from an older version of OS X, you’ll need the Apple ID and password you used to upgrade.
    Step 10
    Repeat Step 9, but this time erase the boot volume in Disk Utility before installing. The system should automatically reboot into the Setup Assistant. Follow the prompts to transfer your data from a Time Machine or other backup.
    Step 11
    This step applies only to models that have a logic-board ("PRAM") battery: all Mac Pro's and some others (not current models.) Both desktop and portable Macs used to have such a battery. The logic-board battery, if there is one, is separate from the main battery of a portable. A dead logic-board battery can cause a boot failure. Typically the failure will be preceded by loss of the settings for the startup disk and system clock. See the user manual for replacement instructions. You may have to take the machine to a service provider to have the battery replaced.
    Step 12
    If you get this far, you're probably dealing with a hardware fault. Make a "Genius" appointment at an Apple Store, or go to another authorized service provider.

  • Use CONTEXT index on mview or use mview's rewrite directly

    Please let me explain what I mean in Subject. I have 9 tables. Each of these tables has about 40,000 rows and one table has 2 million rows. Using first approach, I can build a join-only materialized view on top of nine table's mview log. then query on these nine tables directly. Advantage for doing that is use rewrite.
    <p>
    for second approach, I build a CONETXT index on several columns on the mview, and then query through CONTEXT index on mview directly. This is pretty much like Barbara did on CREATE INDEX book_idx ON book_search
    [http]Indexing multiple columns of multiple tables using CTXCAT
    but she used CTXCAT instead of CONTEXT index.
    <p>
    My question is will second approach better than first one and why. Unlike basic join several tables which gives you predictable performance, I often feel that CONTEXT index performance is unpredictable when tables have more than several thousands rows (maybe I did something wrong, but still looking for document regarding performance) .
    <p>
    I will appreciate someone could show hints on the issue.
    <p>
    Message was edited by:
    qwe15933
    Message was edited by:
    qwe15933
    Message was edited by:
    qwe15933
    Message was edited by:
    qwe15933

    The best method to find out what is best for any individual situation is to test and compare. In general, Oracle Text is best at searching unstructured data, such as large documents and has a lot of features that enable you to do different kinds of searches. If you only have structured data, with each column only containing one short thing and you only need simple searches, then you probably don't need Text. There are also a few things that can be done to indexes and/or queries to optimize performance. It would help to have an idea what your typical data is like and what sorts of searches you anticipate needing.

  • How to get the selected values from a selectmanylistbox?

    Hi ADF Experts,
    <af:selectManyListbox label="Label 1" id="sml1" partialTriggers="cb2"
                            value="#{viewScope.TestBean.lovValue}"
                      autoSubmit="true"      valuePassThru="true">
        <f:selectItems value="#{viewScope.TestBean.actualList}" id="si1"
                       binding="#{viewScope.TestBean.selectedItems}"/>
      </af:selectManyListbox>
      <af:commandButton text="get selected values" id="cb3"
                        actionListener="#{viewScope.TestBean.getSelectedValues}"
                        partialSubmit="true"/>
      private List<String> lovValue;
      private List<SelectItem> actualList;
    //getters and setters
      public void getSelectedValues(ActionEvent actionEvent) {
        // Add event code here...
        for (String selectedItem : lovValue) {
            System.out.println("Selected item: " +selectedItem.); // this is giving 1 and 3 like this. how to get the checked values as I'm getting only the indexes. In this scenario I am populating the list programmatically.Just I wanted to know how can we get the selected values(not indexes). Please suggest.
    Thanks-
    Abhijit

    Hi Timo,
    As I am sharing the page fragment and the Java class. So its my usecase I have mentioned below
    I am sharing the jsff page fragment and java class. So that it wud be of help to others.
    jsff page fragment
    <?xml version='1.0' encoding='UTF-8'?>
    <jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="2.1"
              xmlns:af="http://xmlns.oracle.com/adf/faces/rich"
              xmlns:f="http://java.sun.com/jsf/core">
            <af:panelGroupLayout id="pgl1">
              <af:commandButton text="Search"  id="cb1"
                                actionListener="#{viewScope.TestBean.searchSupplier}"/>
    </af:panelGroupLayout>
        <af:popup id="p1" binding="#{viewScope.TestBean.searchSupplierPopup}">
              <af:dialog id="d2"
                         type="none">
               <af:table value="#{bindings.Contacts.collectionModel}" var="row"
                      rows="#{bindings.Contacts.rangeSize}"
                      emptyText="#{bindings.Contacts.viewable ? 'No data to display.' : 'Access Denied.'}"
                      fetchSize="#{bindings.Contacts.rangeSize}"
                      rowBandingInterval="0"
                      binding="#{viewScope.TestBean.tsupportIssues}"
                      filterModel="#{bindings.ContactsQuery.queryDescriptor}"
                      queryListener="#{bindings.ContactsQuery.processQuery}"
                      filterVisible="true" varStatus="vs"
                      selectionListener="#{bindings.Contacts.collectionModel.makeCurrent}"
                      rowSelection="multiple" id="t1">
              <af:column sortProperty="name" filterable="true" sortable="true"
                         headerText="#{bindings.Contacts.hints.name.label}" id="c2">
                <af:outputText value="#{row.name}" id="ot1"/>
              </af:column>
              <af:column sortProperty="email" filterable="true" sortable="true"
                         headerText="#{bindings.Contacts.hints.email.label}"
                         id="c1">
                <af:outputText value="#{row.email}" id="ot2"/>
              </af:column>
            </af:table>
          <af:commandButton text="OK" id="cb5" partialSubmit="true"       actionListener="#{viewScope.TestBean.testMethod}"/>
          <af:commandButton text="Cancel" id="cb6"
                            actionListener="#{viewScope.TestBean.cancelPopupSearch}"/>
        </af:dialog>
            </af:popup>
      <af:selectManyListbox label="Label 1" id="sml1" partialTriggers="cb5"
                            value="#{viewScope.TestBean.lovValue}"
                      autoSubmit="true"      valuePassThru="true"
                            binding="#{viewScope.TestBean.prp1}">
        <f:selectItems value="#{viewScope.TestBean.actualList}" id="si1"
                       binding="#{viewScope.TestBean.selectedItems}"/>
      </af:selectManyListbox>
      <af:commandButton text="get selected values" id="cb3"
                        actionListener="#{viewScope.TestBean.getSelectedValues}"
                        partialSubmit="true"/>
      <af:commandButton text="remove selected" id="cb4"
             partialSubmit="true"           actionListener="#{viewScope.TestBean.removeSelectedValues}"/>
    </jsp:root>
    TestBean.java
    package com.demo.view;
    import java.util.ArrayList;
    import java.util.Iterator;
    import java.util.List;
    import javax.faces.component.UISelectItems;
    import javax.faces.event.ActionEvent;
    import javax.faces.model.SelectItem;
    import oracle.adf.model.BindingContext;
    import oracle.adf.model.binding.DCBindingContainer;
    import oracle.adf.model.binding.DCIteratorBinding;
    import oracle.adf.view.rich.component.rich.RichPopup;
    import oracle.adf.view.rich.component.rich.data.RichTable;
    import oracle.adf.view.rich.component.rich.input.RichSelectManyListbox;
    import oracle.adf.view.rich.context.AdfFacesContext;
    import oracle.adf.view.rich.event.DialogEvent;
    import oracle.jbo.Key;
    import oracle.jbo.Row;
    import oracle.jbo.RowSetIterator;
    import org.apache.myfaces.trinidad.model.RowKeySet;
    public class TestBean {
      private RichTable tsupportIssues;
      private List<SelectItem> lovValue;
      private List<SelectItem> actualList;
      private RichSelectManyListbox prp1;
      private List valuesChoosed = new ArrayList();
      private UISelectItems selectedItems;
      private RichPopup searchSupplierPopup;
        public TestBean() {
        super();
      public void setTsupportIssues(RichTable tsupportIssues) {
        this.tsupportIssues = tsupportIssues;
      public RichTable getTsupportIssues() {
        return tsupportIssues;
      public void testMethod(ActionEvent actionEvent) {
        // Add event code here...
        // For learning purposes - show Select Many Button clicked 
         System.out.println("Select Many Button has been Clicked");
        // // RowKeySet Object can hold the selected rows from a user as follows    
        RowKeySet rksSelectedRows =         this.getTsupportIssues().getSelectedRowKeys();
        // Iterator object provides the ability to use hasNext(), next() and remove() against the selected rows 
        Iterator itrSelectedRows = rksSelectedRows.iterator();  
        // Get the data control that is bound to the table - e.g.
        // OpenSupportItemsIterator    
        DCBindingContainer bindings =         (DCBindingContainer)BindingContext.getCurrent().getCurrentBindingsEntry(); 
        DCIteratorBinding dcIteratorBindings =         bindings.findIteratorBinding("findAllContactsIterator"); 
        // Information from binding that is specific to the rows  
        RowSetIterator rsiSelectedRows =         dcIteratorBindings.getRowSetIterator();   
        // Loop through selected rows  
        int i=1;
        while (itrSelectedRows.hasNext()) {        
          // Get key for selected row    
          Key key = (Key)((List)itrSelectedRows.next()).get(0);  
          // Use the key to get the data from the above binding that is related to the row      
          Row myRow = rsiSelectedRows.getRow(key);         
          // Display attribute of row in console output - would generally be bound to a UI component like a Label and or used to call another proces       
          System.out.println(myRow.getAttribute("name"));
          valuesChoosed.add(myRow.getAttribute("name"));
    //        actualList = new ArrayList<SelectItem>();
    //        String j = Integer.toString(i);
    //        actualList.add(new SelectItem(j, (String)myRow.getAttribute("name")));
    //      i++;
           searchSupplierPopup.hide();
          AdfFacesContext.getCurrentInstance().addPartialTarget(prp1);
      public void setLovValue(List<SelectItem> lovValue) {
        this.lovValue = lovValue;
      public List<SelectItem> getLovValue() {
        return lovValue;
      public void setActualList(List<SelectItem> actualList) {
        this.actualList = actualList;
      public List<SelectItem> getActualList() {
        actualList = new ArrayList<SelectItem>();
        if(valuesChoosed.size()!=0){
        for(int i=0;i<valuesChoosed.size();i++){
          actualList.add(new SelectItem(valuesChoosed.get(i), (String)valuesChoosed.get(i)));
        else{
          actualList.add(new SelectItem("1","Select One"));
        return actualList;
      public void setPrp1(RichSelectManyListbox prp1) {
        this.prp1 = prp1;
      public RichSelectManyListbox getPrp1() {
        return prp1;
      public void setValuesChoosed(List valuesChoosed) {
        this.valuesChoosed = valuesChoosed;
      public List getValuesChoosed() {
        return valuesChoosed;
      public void getValues(ActionEvent actionEvent) {
        // Add event code here...
        for(int i=0;i<valuesChoosed.size();i++){
          System.out.println(valuesChoosed.get(i));
      public void getSelectedValues(ActionEvent actionEvent) {
        // Add event code here...
         for(int i=0;i<this.getLovValue().size();i++){
             System.out.println("Selected Value:"+this.getLovValue().get(i));
      public void removeSelectedValues(ActionEvent actionEvent) {
        // Add event code here...
      public void setSelectedItems(UISelectItems selectedItems) {
        this.selectedItems = selectedItems;
      public UISelectItems getSelectedItems() {
        return selectedItems;
        public void setSearchSupplierPopup(RichPopup searchSupplierPopup) {
            this.searchSupplierPopup = searchSupplierPopup;
        public RichPopup getSearchSupplierPopup() {
            return searchSupplierPopup;
        public void cancelPopupSearch(ActionEvent actionEvent) {
            // Add event code here...
            searchSupplierPopup.hide();
        public void searchSupplier(ActionEvent actionEvent) {
            // Add event code here...
            RichPopup.PopupHints hints = new RichPopup.PopupHints();
            searchSupplierPopup.show(hints);
    package com.demo.view;
    import java.util.ArrayList;
    import java.util.Iterator;
    import java.util.List;
    import javax.faces.component.UISelectItems;
    import javax.faces.event.ActionEvent;
    import javax.faces.model.SelectItem;
    import oracle.adf.model.BindingContext;
    import oracle.adf.model.binding.DCBindingContainer;
    import oracle.adf.model.binding.DCIteratorBinding;
    import oracle.adf.view.rich.component.rich.RichPopup;
    import oracle.adf.view.rich.component.rich.data.RichTable;
    import oracle.adf.view.rich.component.rich.input.RichSelectManyListbox;
    import oracle.adf.view.rich.context.AdfFacesContext;
    import oracle.adf.view.rich.event.DialogEvent;
    import oracle.jbo.Key;
    import oracle.jbo.Row;
    import oracle.jbo.RowSetIterator;
    import org.apache.myfaces.trinidad.model.RowKeySet;
    public class TestBean {
      private RichTable tsupportIssues;
      private List<SelectItem> lovValue;
      private List<SelectItem> actualList;
      private RichSelectManyListbox prp1;
      private List valuesChoosed = new ArrayList();
      private UISelectItems selectedItems;
      private RichPopup searchSupplierPopup;
        public TestBean() {
        super();
      public void setTsupportIssues(RichTable tsupportIssues) {
        this.tsupportIssues = tsupportIssues;
      public RichTable getTsupportIssues() {
        return tsupportIssues;
      public void testMethod(ActionEvent actionEvent) {
        // Add event code here...
        // For learning purposes - show Select Many Button clicked 
         System.out.println("Select Many Button has been Clicked");
        // // RowKeySet Object can hold the selected rows from a user as follows    
        RowKeySet rksSelectedRows =         this.getTsupportIssues().getSelectedRowKeys();
        // Iterator object provides the ability to use hasNext(), next() and remove() against the selected rows 
        Iterator itrSelectedRows = rksSelectedRows.iterator();  
        // Get the data control that is bound to the table - e.g.
        // OpenSupportItemsIterator    
        DCBindingContainer bindings =         (DCBindingContainer)BindingContext.getCurrent().getCurrentBindingsEntry(); 
        DCIteratorBinding dcIteratorBindings =         bindings.findIteratorBinding("findAllContactsIterator"); 
        // Information from binding that is specific to the rows  
        RowSetIterator rsiSelectedRows =         dcIteratorBindings.getRowSetIterator();   
        // Loop through selected rows  
        int i=1;
        while (itrSelectedRows.hasNext()) {        
          // Get key for selected row    
          Key key = (Key)((List)itrSelectedRows.next()).get(0);  
          // Use the key to get the data from the above binding that is related to the row      
          Row myRow = rsiSelectedRows.getRow(key);         
          // Display attribute of row in console output - would generally be bound to a UI component like a Label and or used to call another proces       
          System.out.println(myRow.getAttribute("name"));
          valuesChoosed.add(myRow.getAttribute("name"));
    //        actualList = new ArrayList<SelectItem>();
    //        String j = Integer.toString(i);
    //        actualList.add(new SelectItem(j, (String)myRow.getAttribute("name")));
    //      i++;
           searchSupplierPopup.hide();
          AdfFacesContext.getCurrentInstance().addPartialTarget(prp1);
      public void setLovValue(List<SelectItem> lovValue) {
        this.lovValue = lovValue;
      public List<SelectItem> getLovValue() {
        return lovValue;
      public void setActualList(List<SelectItem> actualList) {
        this.actualList = actualList;
      public List<SelectItem> getActualList() {
        actualList = new ArrayList<SelectItem>();
        if(valuesChoosed.size()!=0){
        for(int i=0;i<valuesChoosed.size();i++){
          actualList.add(new SelectItem(valuesChoosed.get(i), (String)valuesChoosed.get(i)));
        else{
          actualList.add(new SelectItem("1","Select One"));
        return actualList;
      public void setPrp1(RichSelectManyListbox prp1) {
        this.prp1 = prp1;
      public RichSelectManyListbox getPrp1() {
        return prp1;
      public void setValuesChoosed(List valuesChoosed) {
        this.valuesChoosed = valuesChoosed;
      public List getValuesChoosed() {
        return valuesChoosed;
      public void getValues(ActionEvent actionEvent) {
        // Add event code here...
        for(int i=0;i<valuesChoosed.size();i++){
          System.out.println(valuesChoosed.get(i));
      public void getSelectedValues(ActionEvent actionEvent) {
        // Add event code here...
         for(int i=0;i<this.getLovValue().size();i++){
             System.out.println("Selected Value:"+this.getLovValue().get(i));
      public void removeSelectedValues(ActionEvent actionEvent) {
        // Add event code here...
        for(int i=0;i<this.getLovValue().size();i++){
            System.out.println("Selected Value:"+this.getLovValue().get(i));
            System.out.println(this.getLovValue().remove(i));
          AdfFacesContext.getCurrentInstance().addPartialTarget(prp1);
      public void setSelectedItems(UISelectItems selectedItems) {
        this.selectedItems = selectedItems;
      public UISelectItems getSelectedItems() {
        return selectedItems;
        public void setSearchSupplierPopup(RichPopup searchSupplierPopup) {
            this.searchSupplierPopup = searchSupplierPopup;
        public RichPopup getSearchSupplierPopup() {
            return searchSupplierPopup;
        public void cancelPopupSearch(ActionEvent actionEvent) {
            // Add event code here...
            searchSupplierPopup.hide();
        public void searchSupplier(ActionEvent actionEvent) {
            // Add event code here...
            RichPopup.PopupHints hints = new RichPopup.PopupHints();
            searchSupplierPopup.show(hints);
    Thanks,
    A. Abhijit

Maybe you are looking for