Help with pop-up menu

Im haveing a hard time figuring out how to make a pop-up mene i created work correctly. I what to have a pop-up menu that will let you select a type of item, and return the items associate cost in the adjacent cell.
Exaple:
select option 1-3 in cell "A" and return values x,y & z in cell "B".
I figured out how to create the pop-up in cell "a" but cant seam to fugure out how to give each of the options a seperate value that appears in "b".

Assuming the pop up is in B1:
you could enter the following formula in C1:
=IF(B1=1, "A", IF(B1=2, "B", IF(B1=3, "C", "")))
This will result in the following:
B1 = 1,  C1 will return "A"
B1 = 2,  C1 will return "B"
B1 = 3,  C1 will return "C"
This method is ok for a small translation set.  Much larger and it is hard to change and update.  So the next method is to recognize if there is a pattern.  If there is no pattern then you can make a translation table:
In this case you look up the value "3" in the Data table (column 1) and return the corresponding value from a different cell in the same row (column 2):
B3=VLOOKUP(A1, Data :: A:B, 2, 0)
I hope this helps,
Wayne

Similar Messages

  • Need help with pop-up menu and applied Rules

    I'm working on a spreadsheet that calculates my profit and losses. I drive a big rig so it needs to keep track of a lot of variables so I know if I'm going to make money on a run or lose money.
    I get fuel discounts of various amounts depending on which vendor I fuel at.
    I went to a section of the sheet and did a pop-up menu that contains the vendor names.
    In the trip section I have cost of fuel per gallon, gallons purchased, total fuel cost, cost minus fuel surcharge.
    What I would like to do is apply a rule to cost per gallon box (H7) that takes a variable from the pop-up menu (B40).
    So if H7 has $2.58 entered as a cost and B40 has pilot selected then $0.050 will automatically be deducted from the $2.58. This way I will have a history of where I fuel, the deduction is made automatically, and I have a history of fuel prices in a certain region.
    If anyone looks at this and sees a simpler way of figuring this calculation please make the suggestion. I want to keep this sheet as small and hassle free as possible.
    I have 3 fuel stops per trip with totals that are connected to other areas. Once I get all of this done I will be adding a chart for easy comparison and long range simple tracking to see where improvements can be made and costs are going.
    Thanks in advance all help will be appreciated.
    Message was edited by: Hwoodwriter for clarification.

    The IF Lookup table worked. Did a little modification by placing the table in another part of the chart then hiding that part.
    I tried doing the discount as a negative but got a negative total which had a negative affect on my total trip income.
    Here is how it works in it's final version.
    Gallons on board minus gallons required for trip.
    Cost per gallon (retail) multiplied by gallons purchased.
    Fuel cost equals (Gallons purchased multiplied by Retail gallon price) minus ("IfLookup" multiplied by Gallons purchased)
    Fuel Cost Minus Fuel Surcharge (the actual price I pay, which includes all my savings) equals (Retail Gallon Cost minus Fuel Surcharge minus "IfLookup") multiplied by Gallons Purchased.
    Some of my trips take up to 3 fuel stops. So this helps me keep track of each fuel stop and all savings per trip.
    I now have where I fueled, the retail price, with discount and surcharge applied. A few keystrokes and I know if a trip is going to be profitable or a loss for me.
    Thank you for the help. I now have what I need at my fingertips to make my job more effective.
    Thanks again.

  • Help with pop-up menu --- please!

    I want to see if I can get this simple code working so that I can integrate the ideas into a larger application. But, I'm getting errors on this one! What am I missing or forgetting?
    public class example implements MouseInputListener,MouseMotionListener{
         JPopupMenu menu = new JPopupMenu();
         public static void main (String args[]) {
              Frame f = new Frame();
              {Window w = new Window(f);
              w.setSize(200,100);
              w.setVisible(true);
              w.setLocation(300,300);
              //New Red Window
              {Window w= new warningwindow (f);
              w.setSize(200,100);     //setSize is in a superclass
              w.setVisible(true);
              w.setLocation(370,370);}
              // Create and add a menu item
         JMenuItem item = new JMenuItem("Hi Kimberly!");
         addMouseListener(this); //ERROR WITH THIS LINE
         menu.add(item); //ERROR WITH THIS LINE ALSO
         // Set the component to show the popup menu
         public void mouseClicked (MouseEvent e) {
              if(e.isPopupTrigger()){
                   menu.show(e.getComponent(),e.getX(), e.getY());
         public void mouseReleased (MouseEvent e){
              if (e.isPopupTrigger()){
                   menu.show(e.getComponent(),e.getX(),e.getY());
         public void mouseExited (MouseEvent e){
         public void mouseMoved (MouseEvent e){
         public void mouseDragged (MouseEvent e){
         public void mousePressed (MouseEvent e){
         public void mouseEntered (MouseEvent e){
    }

    You're forgetting that we can't see your computer from here. Tell us what errors you are getting.

  • Need help with pop-up menu please!

    So I have an older version of Dreamweaver.
    I want to apply a drop-down menu or pop-up menu whatever to
    words, but so far I don't think I can do that.
    I've decided to apply it to a picture instead, and I've done
    this successfuly before.
    I select the picture, then go to behaviors and select "show
    pop-up menu", fill in the info and say OK, but I then get this
    message that goes something like "while applying behaviors action
    javascript failed" and "ReferenceError:imgName isNot defined" or
    whatever and it won't let me add it.
    I've restarted the program and even my computer but it won't
    go away.
    Does anyone know how to fix this?
    -anna

    > So I have an older version of Dreamweaver.
    DW4?
    The pop-up menus are very troublesome. Nobody here would
    recommend that you
    use them.
    > Does anyone know how to fix this?
    What is your operating system?
    Murray --- ICQ 71997575
    Adobe Community Expert
    (If you *MUST* email me, don't LAUGH when you do so!)
    ==================
    http://www.dreamweavermx-templates.com
    - Template Triage!
    http://www.projectseven.com/go
    - DW FAQs, Tutorials & Resources
    http://www.dwfaq.com - DW FAQs,
    Tutorials & Resources
    http://www.macromedia.com/support/search/
    - Macromedia (MM) Technotes
    ==================
    "anzya91" <[email protected]> wrote in
    message
    news:eibt0r$esr$[email protected]..
    > So I have an older version of Dreamweaver.
    > I want to apply a drop-down menu or pop-up menu whatever
    to words, but so
    > far
    > I don't think I can do that.
    > I've decided to apply it to a picture instead, and I've
    done this
    > successfuly
    > before.
    > I select the picture, then go to behaviors and select
    "show pop-up menu",
    > fill
    > in the info and say OK, but I then get this message that
    goes something
    > like
    > "while applying behaviors action javascript failed" and
    > "ReferenceError:imgName
    > isNot defined" or whatever and it won't let me add it.
    > I've restarted the program and even my computer but it
    won't go away.
    > Does anyone know how to fix this?
    >
    > -anna
    >

  • "Open with" pop-up menu application list editing

    I have installed Adobe Photoshop CS2 on my iBook G4. When opening .jpg or other file with "Open with" pop-up menu there is alot of applications which gives only a long list for me. How to edit this list.

    hi vienspatsmajas,
    You can try using Zingg! to configure the "open with" menu
    http://www.versiontracker.com/dyn/moreinfo/macosx/12965&vid=130824
    Lori

  • Problem with pop up menu created in fireworks

    I have created a banner with buttons and added a pop up menu to them.
    They work perfectly with-in Fireworks.
    I then export page to dreamweaver and both banner and buttons display properly but I cannot get pop up menu to show at all.
    I want to choose each menu and make the links with-in dreamweaver but cannot get pop up top show.
    I am using CS5 and would appreciate your help.
    AlSO I AM STILL LEARNING SO IF YOU COULD KEEP IT AS SIMPLE AS POSSIBLE I WOULD APPRECIATE IT. 

    HELLO AND THANK YOU FOR YOUR REPLY. I HAVE CREATED A QUICK BANNER WHICH IS SIMILAR TO THE ONE I WANT TO CREATE. THE LIST OF BUTTON ARE  PLACED INTO MY BANNER AND I HAVE ADDED POP UP MENUS TO ALL WITH 3 CELLS DEEP DROPPING DOWNWARDS. WHEN I VIEW THESE IN PREVIEW IN A WEB BROWSER FROM FIREWORKS THEY WORK PERFECTLY. THE PROBLEM IS THAT I DON'T SEEM TO BE ABLE TO MOVE THIS PAGE TO DREAM WEAVER AND HAVE IT DISPLAY THE POP UP MENUS. THEY WILL SHOW AS AN IMAGE AS IT IS SEEN HERE BUT WILL NOT DROP DOWN IN PREVIEW BROWSER IN DREAM WEAVER. I WANT TO BE ABLE TO SELECT THE INDIVIDUAL LISTS IN THE DROP DOWN MENU AND CREATE LINKS TO VARIOUS PAGES WITH-IN MY SITE IN DREAM WEAVER. IT MAY BE THE CASE THAT I AM NOT EXPORTING IT PROPERLY OR SAVING  IT CORRECTLY.

  • Help! Pop-up menu problem

    I made a pop-up menu in a trial version of Fireworks 8.
    Everything works great within Fireworks, but when I try to insert
    it in Dreamweaver 4 (using the Insert Fireworks html button) it
    tells me that I need to insert an Fireworks html that was exported
    from Fireworks. The pop-up menu I made was exported as an html from
    Fireworks. Help!

    I don't think you are going to have much success trying to
    marry DW4 with
    anything contemporary. It's methods and structure are so
    antique, you know?
    Murray --- ICQ 71997575
    Adobe Community Expert
    (If you *MUST* email me, don't LAUGH when you do so!)
    ==================
    http://www.dreamweavermx-templates.com
    - Template Triage!
    http://www.projectseven.com/go
    - DW FAQs, Tutorials & Resources
    http://www.dwfaq.com - DW FAQs,
    Tutorials & Resources
    http://www.macromedia.com/support/search/
    - Macromedia (MM) Technotes
    ==================
    "Erin88" <[email protected]> wrote in
    message
    news:er308c$391$[email protected]..
    >I made a pop-up menu in a trial version of Fireworks 8.
    Everything works
    >great
    > within Fireworks, but when I try to insert it in
    Dreamweaver 4 (using the
    > Insert Fireworks html button) it tells me that I need to
    insert an
    > Fireworks
    > html that was exported from Fireworks. The pop-up menu I
    made was exported
    > as
    > an html from Fireworks. Help!
    >

  • Need help with pop up menus...

    Hi guys, hope u can help me with this. Im working on a flash
    website. I have to include a pop up menu which I have managed to
    create no problem. However, when I try to make the buttons inside
    the pop up to change to another scene when clicked I cant get them
    to work. This is the code I've used:
    on (release) {
    _root.gotoAndStop("Student_area","tests");
    I have defined the action to go to the frame labeled "tests"
    in the "Student_area" scene as I have been told in a tutorial I
    have. However when I test it and click on it nothing happens. I
    have tried many variations such as simply telling it to take me to
    the students scene like I would do with a normal button but still
    nothing happens.
    What am I doing wrong?
    Hope someone can help me, gotta submit this soon.
    Thanks in advance.

    bump...
    Anyone?? Please.

  • Need Help: JTable POP up menu in a CellEditor to display on a right click

    This was from a previous post:
    I am trying to make a POP menu in a JTextComponent that has a assigned JEditorPane for a HTMLDocument to make use of the HTMLEditorKit to allow modifying HTML by the POP up menu.
    import java.awt.*;
    import java.awt.event.*;
    import java.io.*;
    import java.net.*;
    import java.util.*;
    import javax.swing.*;
    import javax.swing.event.*;
    import javax.swing.text.*;
    import javax.swing.table.*;
    import javax.swing.text.html.*;
    import javax.swing.undo.*;
    import javax.swing.border.*;
    import javax.swing.filechooser.*;
    public class SimpleTableDemo extends JFrame {
        public SimpleTableDemo() throws Exception {
            final JTable table = new JTable(new MyTableModel());
            table.setPreferredScrollableViewportSize(new Dimension(500, 70));
            TableColumn fileColumn = table.getColumnModel().getColumn(2);
            FileTableCellEditor editor = new FileTableCellEditor();
            fileColumn.setCellRenderer(editor);
            fileColumn.setCellEditor(editor);
            JScrollPane scrollPane = new JScrollPane(table);
            getContentPane().add(scrollPane, BorderLayout.CENTER);
            addWindowListener(new WindowAdapter() {
                public void windowClosing(WindowEvent e) {
                System.exit(0);
                table.setRowHeight(100);
            public static void main(String[] args) throws Exception {
                SimpleTableDemo frame = new SimpleTableDemo();
                frame.pack();
                frame.setVisible(true);
            class MyTableModel extends AbstractTableModel {
                String[] columnNames = {"First Name","Last Name","HTML File"};
                public Object[][] data;
                MyTableModel() throws Exception
                    data = createArray();
                private Object[][] createArray() throws Exception
                    Object[][] data = {{"One", "Andrews", createDoc("file1.html")}
                return data;
                private Document createDoc(String url) throws Exception
                    File file = new File(url);
                    URL baseURL = file.toURL();
                    InputStream in = baseURL.openStream();
                    InputStreamReader r = new InputStreamReader(filterTag(in));
                    HTMLEditorKit kit = new HTMLEditorKit();
                Document doc = kit.createDefaultDocument();
                kit.read(r,doc,0);
                return doc;
                } // workaround for HTMLEditorKit.Parser, cant deal with "content-encoding"
                private InputStream filterTag(InputStream in) throws IOException {
                    DataInputStream dins = new DataInputStream( in);
                    ByteArrayOutputStream bos = new ByteArrayOutputStream(10000);
                    DataInputStream din = new DataInputStream(new BufferedInputStream(in));
                    while (din.available() > 0) {
                    String line = din.readLine();
                    String lline = line.toLowerCase();
                    if (0 <= lline.indexOf("<meta ")) // skip meta tags
                    continue;
                    bos.write( line.getBytes());
                    din.close();
                    return new ByteArrayInputStream( bos.toByteArray());
                public int getColumnCount() {
                    return columnNames.length;
                public int getRowCount() {
                    return data.length;
                public String getColumnName(int col) {
                    return columnNames[col];
                public Object getValueAt(int row, int col) {
                    return data[row][col];
                public Class getColumnClass(int c) {
                    return getValueAt(0, c).getClass();
                public boolean isCellEditable(int row, int col) {
                if (col >< 1) {
                    return false;
                } else {
                    return true;
    public class FileTableCellEditor extends JScrollPane implements TableCellEditor , TableCellRenderer
        public JTextComponent jtext;
        JEditorPane editor;
        HTMLEditorKit kit = new HTMLEditorKit();
        HTMLDocument doc = new HTMLDocument();;
        private EventListenerList listenerList = new EventListenerList();
        private ChangeEvent event = new ChangeEvent(this);
        public FileTableCellEditor()
        editor = new JEditorPane();
        editor.setContentType("text/html");
        doc=new HTMLDocument();
        editor.addMouseListener(new MouseHandler());
        editor.setEditorKit(kit);
        editor.setDocument(doc);
        editor.setEditable(true);
        editor.setCaretColor(Color.RED);
        getViewport().setView(editor);
        setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED);
        setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);
        public Component getTableCellRendererComponent(JTable table, Object value,
        boolean isSelected, boolean hasFocus, int row, int column)
            // System.out.println("has focus: "+hasFocus+", isSelected: "+isSelected);
            if (isSelected)
            table.editCellAt(row,column);
        table.editCellAt(row,column);
        return getTableCellEditorComponent(table,value,isSelected, row, column);
        public Component getTableCellEditorComponent(JTable table,
        Object value, boolean isSelected, int row, int column)
        editor.setDocument((Document)value);
        return this;
        public boolean isCellEditable(EventObject anEvent)
        { return true;
        public boolean shouldSelectCell(EventObject anEvent)
        { return true;
        public void cancelCellEditing()
        { fireEditingStopped();
        public boolean stopCellEditing()
        { return true;
        public Object getCellEditorValue()
        { return null;
        public void addCellEditorListener(CellEditorListener l)
        { listenerList.add(CellEditorListener.class, l);
        public void removeCellEditorListener(CellEditorListener l)
        { listenerList.remove(CellEditorListener.class, l);
        protected void fireEditingStopped()
        { Object[] listeners = listenerList.getListenerList();
        for (int i = listeners.length - 2; i >= 0; i -= 2)
        ((CellEditorListener)listeners[i+1]).
        editingStopped(event);
        protected void fireEditingCanceled()
        { Object[] listeners = listenerList.getListenerList();
        for (int i = listeners.length - 2; i >= 0; i -= 2)
        ((CellEditorListener)listeners[i+1]).
        editingCanceled(event);
            ///////////createPopupMenu///////////////
            protected JPopupMenu createPopupMenu()
            JPopupMenu popup =new JPopupMenu();
            popup.add(getTextComponent().getActionMap().get(HTMLEditorKit.cutAction)).setAccelerator(null);
            popup.add(getTextComponent().getActionMap().get(HTMLEditorKit.copyAction)).setAccelerator(null);
            popup.add(getTextComponent().getActionMap().get(HTMLEditorKit.pasteAction)).setAccelerator(null);
            popup.addSeparator();
            popup.add(getTextComponent().getActionMap().get("font-bold"));
            popup.add(getTextComponent().getActionMap().get("font-italic"));
            popup.add(getTextComponent().getActionMap().get("font-underline"));
            //popup.add(getTextComponent().getActionMap().get("break"));
            return popup;
        public JTextComponent getTextComponent()
             return jtext;
        protected class MouseHandler extends MouseAdapter{
           public void mouseReleased(MouseEvent me){
               if(me.getButton()==MouseEvent.BUTTON3){
               Point p=me.getPoint();
               createPopupMenu().show((Component)me.getSource(),p.x,p.y);
    }

    I got the pop up to work, I had to go back to and add a createActionTable editor that is a JEditorPane, vs the JTextComponent!
    Here is the latest version:
    import java.awt.*;
    import java.awt.event.*;
    import java.io.*;
    import java.net.*;
    import java.util.*;
    import java.util.HashMap;
    import javax.swing.*;
    import javax.swing.undo.*;
    import javax.swing.event.*;
    import javax.swing.text.*;
    import javax.swing.table.*;
    import javax.swing.text.html.*;
    import javax.swing.undo.*;
    import javax.swing.border.*;
    import javax.swing.filechooser.*;
    public class SimpleTableDemo extends JFrame {
        public SimpleTableDemo() throws Exception {
            final JTable table = new JTable(new MyTableModel());
            table.setPreferredScrollableViewportSize(new Dimension(500, 70));
            TableColumn fileColumn = table.getColumnModel().getColumn(2);
            FileTableCellEditor editor = new FileTableCellEditor();
            fileColumn.setCellRenderer(editor);
            fileColumn.setCellEditor(editor);
            JScrollPane scrollPane = new JScrollPane(table);
            getContentPane().add(scrollPane, BorderLayout.CENTER);
            addWindowListener(new WindowAdapter() {
                public void windowClosing(WindowEvent e) {
                System.exit(0);
                table.setRowHeight(100);
            public static void main(String[] args) throws Exception {
                SimpleTableDemo frame = new SimpleTableDemo();
                frame.pack();
                frame.setVisible(true);
            class MyTableModel extends AbstractTableModel {
                String[] columnNames = {"First Name","Last Name","HTML File"};
                public Object[][] data;
                MyTableModel() throws Exception
                    data = createArray();
                private Object[][] createArray() throws Exception
                    Object[][] data = {{"One", "Andrews", createDoc("file1.html")}
                return data;
                private Document createDoc(String url) throws Exception
                    File file = new File(url);
                    URL baseURL = file.toURL();
                    InputStream in = baseURL.openStream();
                    InputStreamReader r = new InputStreamReader(filterTag(in));
                    HTMLEditorKit kit = new HTMLEditorKit();
                Document doc = kit.createDefaultDocument();
                kit.read(r,doc,0);
                return doc;
                } // workaround for HTMLEditorKit.Parser, cant deal with "content-encoding"
                private InputStream filterTag(InputStream in) throws IOException {
                    DataInputStream dins = new DataInputStream( in);
                    ByteArrayOutputStream bos = new ByteArrayOutputStream(10000);
                    DataInputStream din = new DataInputStream(new BufferedInputStream(in));
                    while (din.available() > 0) {
                    String line = din.readLine();
                    String lline = line.toLowerCase();
                    if (0 <= lline.indexOf("<meta ")) // skip meta tags
                    continue;
                    bos.write( line.getBytes());
                    din.close();
                    return new ByteArrayInputStream( bos.toByteArray());
                public int getColumnCount() {
                    return columnNames.length;
                public int getRowCount() {
                    return data.length;
                public String getColumnName(int col) {
                    return columnNames[col];
                public Object getValueAt(int row, int col) {
                    return data[row][col];
                public Class getColumnClass(int c) {
                    return getValueAt(0, c).getClass();
                public boolean isCellEditable(int row, int col) {
                if (col < 1) {
                    return false;
                } else {
                    return true;
    public class FileTableCellEditor extends JScrollPane implements TableCellEditor , TableCellRenderer
        JEditorPane editor = new JEditorPane();
        HTMLEditorKit kit = new HTMLEditorKit();
        HTMLDocument doc = new HTMLDocument();;
        private EventListenerList listenerList = new EventListenerList();
        private ChangeEvent event = new ChangeEvent(this);
        HashMap<Object, Action> actions;
        public FileTableCellEditor()
        getContentPane();
        editor.setContentType("text/html");
        doc=new HTMLDocument();
        editor.addMouseListener(new MouseHandler());
        editor.setEditorKit(kit);
        editor.setDocument(doc);
        editor.setEditable(true);
        editor.setCaretColor(Color.RED);
        getViewport().setView(editor);
        createActionTable(editor);
        makeActionsPretty();
        setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED);
        setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);
        public void makeActionsPretty(){
             Action a;
                      a=editor.getActionMap().get(HTMLEditorKit.cutAction);
                      a.putValue(Action.SHORT_DESCRIPTION,"Cut");
                      a.putValue(Action.ACCELERATOR_KEY,KeyStroke.getKeyStroke('X',Event.CTRL_MASK));
                      a=editor.getActionMap().get(HTMLEditorKit.copyAction);
                      a.putValue(Action.NAME,"Copy");
                      a.putValue(Action.SHORT_DESCRIPTION,"Copy");
                      a.putValue(Action.ACCELERATOR_KEY,KeyStroke.getKeyStroke('C',Event.CTRL_MASK));
                      a=editor.getActionMap().get(HTMLEditorKit.pasteAction);
                      a.putValue(Action.NAME,"Paste");
                      a.putValue(Action.SHORT_DESCRIPTION,"Paste");
                      a.putValue(Action.ACCELERATOR_KEY,KeyStroke.getKeyStroke('V',Event.CTRL_MASK));
        public Component getTableCellRendererComponent(JTable table, Object value,
        boolean isSelected, boolean hasFocus, int row, int column)
            if (isSelected)
            table.editCellAt(row,column);
        table.editCellAt(row,column);
        return getTableCellEditorComponent(table,value,isSelected, row, column);
        public Component getTableCellEditorComponent(JTable table,
        Object value, boolean isSelected, int row, int column)
        editor.setDocument((Document)value);
        return this;
        public boolean isCellEditable(EventObject anEvent)
        { return true;
        public boolean shouldSelectCell(EventObject anEvent)
        { return true;
        public void cancelCellEditing()
        { fireEditingStopped();
        public boolean stopCellEditing()
        { return true;
        public Object getCellEditorValue()
        { return null;
        public void addCellEditorListener(CellEditorListener l)
        { listenerList.add(CellEditorListener.class, l);
        public void removeCellEditorListener(CellEditorListener l)
        { listenerList.remove(CellEditorListener.class, l);
        protected void fireEditingStopped()
        { Object[] listeners = listenerList.getListenerList();
        for (int i = listeners.length - 2; i >= 0; i -= 2)
        ((CellEditorListener)listeners[i+1]).
        editingStopped(event);
        protected JPopupMenu createPopupMenu()
            JPopupMenu popup =new JPopupMenu();
            popup.add(getActionByName(DefaultEditorKit.cutAction));
            return popup;
        protected class MouseHandler extends MouseAdapter{
           public void mouseReleased(MouseEvent me){
               if(me.getButton()==MouseEvent.BUTTON3){
               Point p=me.getPoint();
               createPopupMenu().show((Component)me.getSource(),p.x,p.y);
        private void createActionTable(JTextComponent textComponent) {
            actions = new HashMap<Object, Action>();
            Action[] actionsArray = textComponent.getActions();
            for (int i = 0; i < actionsArray.length; i++) {
                Action a = actionsArray;
    actions.put(a.getValue(Action.NAME), a);
    private Action getActionByName(String name) {
    return actions.get(name);

  • Rollovers with Pop up Menu

    The last time I tried to do rollovers with a pop up menu in
    Dreamweaver 8. It wouldn't work. So I'm searching for another way
    to do it.
    I created navigation using Fireworks - follow link below to
    example. But when I mouse over the rollover that has a pop up menu
    attached to it (First link on the left) the rollover images
    disappear. Also the drop down menu tends to hang down longer than I
    would like.
    Can my problems be fixed? Is Fireworks the right tool for
    this task?
    I had down loaded a trial of the latest version of
    Dreamweaver a few months ago and it seemed that this feature had
    been deprecated, but there was some sort of plug-in. I'm far from a
    casual user, but it was beyond me for the weekend I tried to use
    it. Also, this is a bad time for me to invest in new software or
    upgrades.
    Any assistance would be greatly appreciated.
    Example of rollover and
    pop up menu problem

    Don't use Fireworks to make HTML,
    especially interactive HTML. Fireworks is a great tool for
    making Web graphics, but it is
    NOT
    good for making HTML. Don't go there. You won't be happy.
    Read this:
    The
    Sordid Tale of mm_menu and fw_menu.js and then save yourself
    loads of frustration and go buy yourself a professional menu.
    What's your billing rate? At $20/hr a $100 professional menu that
    works, cross-browser, beautifully, is going to save you more
    than 5 hours of hassle trying to get this stuff in Fireworks to
    halfway...kinda...function...almost.
    I don't use these kind of menus, but I've seen this question
    asked often enough to know that one recommendation is the code from
    Project
    7.

  • Help with a Spry Menu Bar

    I'm having trouble with a Spry Menu Bar not displaying
    correctly in Internet Explorer, while it displays fine in every
    other browser I have available. I've done some searching on these
    boards, but the queries I've found with the same type of problem
    each has a knowledgeable person editing the code for the
    poster...and I can't seem to make heads or tails of it.
    So, below is my link. What you'll see if viewed in Explorer
    is that the "Clinics" listing and the "Services & Specialties"
    listing are each on the same horizontal line, rather than vertical
    like the rest of the menu. If anyone can help me in correcting this
    problem, I'd be very appreciative.
    Thanks in advance.
    http://www.chambershospital.com/temp/about.html

    Hello,
    You might try removing all of the <div> tags you
    inserted in the menu.
    This can happen if you select text in design view and use the
    "align" icons
    in the properties window instead of using CSS to align
    things.
    For example:
    <li>
    <div align="left"><<****REMOVE THIS
    <a href="clinics.html"
    class="MenuBarItemSubmenu">Clinics</a>
    <ul>
    <li><a href="clinic.html">Chambers
    Clinic</a></li>
    <li><a href="clinic7.html">Scenic 7
    Clinic</a></li>
    </ul>
    </div><<*** REMOVE THIS
    </li>
    So it looks like this:
    <li><a href="clinics.html"
    class="MenuBarItemSubmenu">Clinics</a>
    <ul>
    <li><a href="clinic.html">Chambers
    Clinic</a></li>
    <li><a href="clinic7.html">Scenic 7
    Clinic</a></li>
    </ul>
    </li>
    Repeat for all the other <div align="left"> and
    </div> tags in the menu.
    Take care,
    Tim
    "Zim74" <[email protected]> wrote in message
    news:fv4vc0$r0t$[email protected]..
    > I'm having trouble with a Spry Menu Bar not displaying
    correctly in
    > Internet
    > Explorer, while it displays fine in every other browser
    I have available.
    > I've
    > done some searching on these boards, but the queries
    I've found with the
    > same
    > type of problem each has a knowledgeable person editing
    the code for the
    > poster...and I can't seem to make heads or tails of it.
    >
    > So, below is my link. What you'll see if viewed in
    Explorer is that the
    > "Clinics" listing and the "Services & Specialties"
    listing are each on the
    > same
    > horizontal line, rather than vertical like the rest of
    the menu. If
    > anyone can
    > help me in correcting this problem, I'd be very
    appreciative.
    >
    > Thanks in advance.
    >
    >
    http://www.chambershospital.com/temp/about.html
    >
    >

  • Help with spry tabbed menu bar

    Hi.
    I need help with the spry tabbed menu panel (horizontal) It
    works fine in dreamweaver ( pressing f12 ) but when i goto my
    website www.so-nouveau.com it puts it all over and not in boxes
    either just the writing.
    I ahve double checked all uploading is correct and files are
    located but it wont work.
    Here is what i did >
    new> html> 1 column elastic,centered. i have not
    changed any other settings at all. Do i need to change the doc type
    or css layout in the drop down menus before starting (doc
    type=xhtnl 1.0 transitional and layout css=add to head)
    I am still on cs3 , does this matter ? or is 4 easier ?
    any help out there guys is much appreciated but please bear
    in mind that i am not a web designer or pc expert at all , this is
    just me building my own site , until nowit has been an enjoyable
    experience but grrrrrr when it dont work
    Thanks
    Jay

    so-nouveau wrote:
    > Hi.
    > I need help with the spry tabbed menu panel (horizontal)
    It works fine in
    > dreamweaver ( pressing f12 ) but when i goto my website
    www.so-nouveau.com it
    > puts it all over and not in boxes either just the
    writing.
    Please post links directly to the page having an issue. I saw
    no tabs on the home page, but I noticed that there is a link on the
    bottom of the page to this page that has a Spry tab on it:
    http://www.so-nouveau.com/test%208.html
    > I ahve double checked all uploading is correct and files
    are located but it
    > wont work.
    That page refers to a Spry JavaScript file and a Spry CSS
    file, which should be at the following locations but are not
    present:
    http://www.so-nouveau.com/SpryAssets/SpryTabbedPanels.js
    http://www.so-nouveau.com/SpryAssets/SpryTabbedPanels.css
    Make sure you upload the SpryAssests folder and see where
    you're at after that.
    Danilo Celic
    |
    http://blog.extensioneering.com/
    | WebAssist Extensioneer
    | Adobe Community Expert

  • PDF with pop-up menu to change page

    Can I create a PDF in Pro that has a pop-up menu (or other simple selection method) that allows user to select an item in list which will change the displayed page?

    You'll probably want to use something like this.pageNum = 5; etc., and have all that embedded in an if conditional (or a switch conditional, which is probably what I'd use).
    A good place to get started with JavaScript is here, although you'll have to look here for the PDF specific stuff (navigate to the JavaScript API).
    The basic idea is that you create a variable for your button (that's the var cRtn stuff), and the value of the variable is updated depending on the user's action. So, if user chooses a popup menu item named Section 1, the value of cRtn becomes Section 1, and you can then add something like
    if (cRtn = "Section 1") this.pageNum = 5;
    Which would send the user to page 5 if they select Section 1 from the popup menu.
    Hope that doesn't sound too cryptic!

  • Show/Hide layer with Pop-up menu

    I love the fact that we are talking about websites here and this one WORKS LIKE ****...and that's diarrhea. I have been trying to just get on this ******* forum to ask this question for 2 days.
    Anyway, I typed this out earlier but it wasn't accepted, I don't know why. Let's see if this one works.
    I am not a code monkey, not even really a web person. I am doing this for a friend, so I can't understand really complicated answers. BUT, here's my problem: I want to make two layers disappear in my index page because they interfere with the pop-up menu of another layer. This, I can do. BUT, I want these layers to reappear when someone moves off the POP-UP, not the link. When I use the "behaviors" that come with Dreamweaver, they all relate only to the link, not the Pop-up menu, so as soon as a user moves down the pop-up menu and off the link, the two layers reappear.
    Here is what I'm talking about, if that doesn't make too much sense:
    http://www.animalcrackerspetsupply.com/Index1.html
    Thank you for reading this and, please, Adobe people, can you make it simpler to get into the forum?
    Kelly

    I didn't realise that f*r*i*g*g*e*n was a naughty word here in the USA.
    The link that I am referring to is found under the "CATS" heading.....

  • Retain button over state with Pop-up Menu

    Hi,
    I am trying to work out how to retain button over state while
    scrolling over a pop-up menu. By default the button changes back to
    mouse out state, when scrolling over menu items for that button.
    I have tried to follow the advice in the below technote (see
    link below), but it seems the instructions are incorrect.
    I am using Fireworks 8 - it appears the instructions are for
    a prior version. I cannot find function fwLoadMenus() mentioned in
    Step 3 (number 6.).
    Has anyone accomplished this in Fireworks 8, that could
    provide me with instructions?
    Thanks in advance,
    turpya.
    http://www.adobe.com/cfusion/knowledgebase/index.cfm?id=tn_15926

    I just wouldn't use those menus at all - there are much
    better ways. Have
    you considered them?
    Check the uberlink and MacFly tutorials at PVII -
    http://www.projectseven.com/
    and the Navbar tutorial/articles at Thierry's place
    http://tjkdesign.com/articles/dropdown/
    Or this one (more recent article):
    http://tjkdesign.com/articles/Pure_CSS_Dropdown_Menus.asp
    Or to get it done fast, go here -
    http://www.projectseven.com/tutorials/navigation/auto_hide/index.htm
    Murray --- ICQ 71997575
    Adobe Community Expert
    (If you *MUST* email me, don't LAUGH when you do so!)
    ==================
    http://www.dreamweavermx-templates.com
    - Template Triage!
    http://www.projectseven.com/go
    - DW FAQs, Tutorials & Resources
    http://www.dwfaq.com - DW FAQs,
    Tutorials & Resources
    http://www.macromedia.com/support/search/
    - Macromedia (MM) Technotes
    ==================
    "turpya" <[email protected]> wrote in
    message
    news:f2ilfs$7gr$[email protected]..
    > Hi,
    >
    > I am trying to work out how to retain button over state
    while scrolling
    > over a
    > pop-up menu. By default the button changes back to mouse
    out state, when
    > scrolling over menu items for that button.
    >
    > I have tried to follow the advice in the below technote
    (see link below),
    > but
    > it seems the instructions are incorrect.
    >
    > I am using Fireworks 8 - it appears the instructions are
    for a prior
    > version.
    > I cannot find function fwLoadMenus() mentioned in Step 3
    (number 6.).
    >
    > Has anyone accomplished this in Fireworks 8, that could
    provide me with
    > instructions?
    >
    > Thanks in advance,
    >
    > turpya.
    >
    >
    http://www.adobe.com/cfusion/knowledgebase/index.cfm?id=tn_15926
    >

Maybe you are looking for

  • Reading a Txt file from SDCard...advise sought.

    Hey, Just a quick post to see if any of you kind people would be able to help me out here. I'm intending to have a database (simply perhaps as just text in a .txt file) stored on my SDCard on my Palm and want to be able to read in that file and in tu

  • .png images in Adobe Connect

    Has anyone else encountered issues with .png images within a PowerPoint converting incorrectly in Adobe Connect?  They appear distorted.

  • Anyone else having trouble with the iPad cover? Mine just keeps falling off!

    The magnets in the cover appear to have become weak meaning that the cover just keeps Falling off after only having it for a few weeks! The magnets have also left horrible black marks on the back of the iPad!

  • Management Cockpit-Display Table

    Hi, I have a frame, in which Disply Table has been activated. In the web reports and Portal this table is diaplyed but the legend has a different colour than in the frame itself. How the legend of the table is controlled? Please advise. Regards, UR

  • PASS THROUGH MAIN grrr!

    I have just exported my imovie project onto idvd and decided to use the quite funky looking "Pass Through" theme. The problem is that although I can change the title, the words "Pass Through Main" keep scrolling across instead of the correct title. I