JSwing code errors with mouse over

Basically this code is set up to change the background of Jtextfield when the Jtextfield contains the cursor. But, it seems that i have issues because it only works if the cursor is in the upper corner of my window frame. I think it has something to do with my hiearchy, but am unsure how to fix.. help will greatly be apreciated.
its in two seperate class files by the way.
import javax.swing.*;
public class yahtzeeTest
      public static void main(String[] args)
     tes menu=new yahtzee();
     JFrame appFrame=new JFrame();
     appFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
     appFrame.setContentPane(menu);
     appFrame.pack();
     appFrame.show();     
// seperate file
import javax.swing.*;
import java.awt.*;
import java.awt.event.*;
import java.awt.geom.*;
public class testeld extends JPanel implements ActionListener, MouseMotionListener
     private static int      panelW = 400,
                              panelH=350;
     JTextField tf[]=new JTextField[2];
       Point cursor;
     public testeld()
     setPreferredSize(new Dimension(panelW, panelH));
     setLayout(null);
     addMouseMotionListener(this);
     setBackground(Color.red);
          for(int i=0; i<2;i++)
          tf=new JTextField( "",i);
          tf[i].setBounds(200, (30+(26*i)), 30,20);
          tf[i].setEnabled(false);
          add(tf[i]);
          tf[i].addActionListener(this);     
     public void actionPerformed(ActionEvent ae)
          Object src = ae.getSource();
     public void paintComponent(Graphics g)
          super.paintComponent(g);
          Graphics2D g2=(Graphics2D)g;
     public void mouseMoved(MouseEvent me)
     int x=me.getX();
     int y=me.getY();
     this.cursor =new Point(x, y);     
     for(int i=0; i<tf.length; i++)
          if(tf[i].contains(cursor))
               tf[i].setBackground(Color.yellow);
          else
               tf[i].setBackground(Color.white);
     public void mouseDragged(MouseEvent me){}

1) Swing related questions should be posted in the Swing forum.
2) I would use the mouseEntered, mouseExited events to set/reset the background.
3) Why did you overried paintComponent()

Similar Messages

  • How can I make photos on web page enlarge with mouse-over?

    How can I make photos on web page enlarge with mouse-over?

    There's a couple of recent topics which mention MagicZoom and JQZoom...
    https://discussions.apple.com/message/17438064#17438064
    https://discussions.apple.com/message/17440847#17440847
    A very simple method is shown here...
    https://discussions.apple.com/message/17440847#17440847

  • JScript Error when mouse over active session chart.

    Whenever I mouse over the chart to change the vertical box indicating the time slice you're dealing with I get an error.
    It says:
    'tipBoxNode' is null or not an object
    line: 153, column 11
    Not sure what to say. I have the latest SVG installed. I'm using IE7
    The OEM version says:
    Oracle Enterprise Manager 10g Release 4 Grid Control 10.2.0.4.0

    'tipBoxNode' is null or not an object
    line: 153, column 11Getting "'tipboxnode' is null" message from 10.2.0.4 Grid Control
    https://metalink.oracle.com/metalink/plsql/ml2_documents.showDocument?p_database_id=NOT&p_id=565594.1
    Top Activity Chart Errors: 'TIPBOXNODE IS NULL OR NOT AN OBJECT' ERROR IN TOP ACTIVITY PAGE
    https://metalink.oracle.com/metalink/plsql/ml2_documents.showDocument?p_database_id=NOT&p_id=737052.1

  • Problem/bug with mouse over movieclips

    Been facing an annoying problem at here: www.villielain.com
    Different site sections are located in animated objects
    (mostly glowing) and when you mouse-over them the bottom menubar
    shows up. The problem is that, when you go fast over multiple
    objects (for example tv - cross - wall), the menu bar won't go
    away.
    I've separate actionscript layer for the menu items and can
    send the original open file if it helps.
    any suggestions? thanks.

    Issue 1: If the user leaves the Flash area (and moves over to
    the black html background in this case), Flash doesn't register a
    RollOut event, because Flash isn't underneath your mouse to capture
    it.
    Issue 2: Another problem is that when you display a new menu,
    your code should remove or override any menu that's currently
    displayed, rather than just adding a new menu to the stage or
    making a new item visible.
    Issue 2 can be fixed with some improved code. Issue 1 is a
    Flash (AS2) limitation, but there are some workarounds. You can
    start a timer when a button is rolled over. If no rollout event is
    triggered after the designated time has elapsed, you can check the
    location of the mouse and perform a hit test with your button.
    Solving issue 2 will also reduce the occurrences of issue 1.

  • VBA Code error with Adobe Acrobat 10 Type Library

    Hi,
    I have some code I created in Word VBA to combine several separate PDFs into a single PDF.  The code works fine with the Adobe Acrobat 9.0 Type Library and Adobe Reader 9.0 installed.
    But, with the Adobe Acrobat 10 Type Library and Adobe Reader 10 installed, the code fails at the marked code below.  Any suggestions??
        Dim acrobatApp As Acrobat.acroApp
        Set acrobatApp = CreateObject("AcroExch.App")
        Dim mainPDF As Acrobat.AcroPDDoc
        Set mainPDF = CreateObject("AcroExch.PDDoc")  ****THIS IS WHERE THE CODE STOPS WITH A "TYPE MISMATCH" ERROR****
        Dim nextPage As Acrobat.AcroPDDoc
        Set nextPage = CreateObject("AcroExch.PDDoc")
        Dim numPages As Integer
        'Loop through all selected VLS, and add each one to the end of the main PDF
        For i = 0 To lstSelected.ListCount - 1
            mainPDF.Open CurDir & "\" & Replace(ThisDocument.Name, ".doc", "") & ".pdf"
            numPages = mainPDF.GetNumPages
            nextPage.Open lstSelected.List(i)
            If mainPDF.InsertPages(numPages - 1, nextPage, 0, nextPage.GetNumPages, True) = False Then
                MsgBox "Cannot insert pages"
            End If
            If mainPDF.Save(PDSaveFull, CurDir & "\" & Replace(ThisDocument.Name, ".doc", "") & ".pdf") = False Then
                MsgBox "Cannot save"
            End If
            'MsgBox lstSelected.List(i)
            nextPage.Close
        Next i

    What if you start with a really simple VBA example? Take a look at this:
    Private Sub CommandButton1_Click()
        Dim AcroApp As Acrobat.CAcroApp
        Dim theDocument As Acrobat.CAcroPDDoc
        Dim bm As Acrobat.AcroPDBookmark
        Dim thePath As String
        thePath = "c:\temp\test.pdf"
        Set AcroApp = CreateObject("AcroExch.App")
        Set theDocument = CreateObject("AcroExch.PDDoc")
        theDocument.Open (thePath)
        MsgBox "Number of pages: " & theDocument.GetNumPages
        theDocument.Close
        AcroApp.Exit
        Set AcroApp = Nothing
        Set theDocument = Nothing
        Set bm = Nothing
        MsgBox "Done"
    End Sub
    If this still does not work, I would reinstall Acrobat to make sure that
    the TLB is not corrupt.
    Karl Heinz Kremer
    PDF Acrobatics Without a Net
    [email protected]
    http://www.khkonsulting.com

  • Interactive PDF with mouse-overs was created in Illustrator, now pauses and flashes when opened in Acrobat

    I have created an interactive PDF using Illustrator that has mouse-overs. When i export the file and then open it in Acrobat there is odd pausing on teh image bewteen mousing over it and the text callout that shold then display. Did I export or save incorrectly?

    Thank you for both responses! I'm impressed with the fact that you're reading my post.
    I'm new to tech matters with Adobe/PDF/Nitro tho I've been using them for several years.
    The original file was created by an agency and given to independent contractor to use.  I don't know which program they used to create the form. And I don't know what XFA or LiveCycle Designer means  because I'm not technically sophisticated unfortunately.
    I used Nitro 6 to populate the data and have a number of forms already filled out, which I periodically open and modify and resubmit. But Nitro 6 is acting sick, despite reinstalling several times.  I'm attempting to see if it's worth transitioning to Adobe Acrobat, i.e., can I reopen the forms I've populated and continue to work with them.  I like some of the Adobe features for other purposes (e.g., OCR). 
    Any help in determining how to open the form while keeping the data?

  • Problem with mouse-over value on a column chart (by Series)

    Hi.
    First of all thanks for any offered tip.
    I am having a problem with a column chart.
    When I move the mouse over a column it should show a small pop-up (or tip) with the column name (series name) and the value (series value). The problem is that it displays an extra '1' just like the following:
    SeriesName
    1
    X.XXX
    How can I remove the extra '1' and only show the name and the value ?
    The data is populated by series (manually added).
    Mihai.

    Hi,
    Thanks for the tip Shanthakumar KA.
    Yes. It looks like the '1' is coming from the X Axis labels. The chart that I have built does not require any labels on the X Axis, so this was not set (X-Axis labels: Empty). I tried setting this to an empty cell, but the '1' still appears in the mouse-over tip.
    It is very weird. If I leave the X-Axis labels empty, I still get the '1' displayed which is very annoing.
    Are there any solutions for this except the re-building the tip with a label a.k.a. '[customize the mouse over values|http://xcelsiusandme.blogspot.com/2009/07/xm-sample-7-customizing-mouse-over.html].'
    Regards,
    Mihai.

  • Applescript 'Contacts' code error with Maverick

    After upgrading from MacOSX 10.6.8 to Maverick my applescripts are creating errors. One example is the following script which works fine if you run it from within the 'Applescript Editor.app' (v 2.6.1) under Maverick but creates a "Data paste section" error -1743 from the 'Contacts' app if you run the script indpendently. Any hints anyone on how I might return this script to full indpendent functionality?
    Script to load a raw address for conversion and inserting into Address Book
    Wish list
    1.    Check if 'New Address' Group already exists and if it doesn't then create one.
    2.    Provide a dialog that enables the user to specify which group to attach the new address to.
    3.    Find the new address and show it in Address Book.
    4.    Create a list of existing Groups to chose from to reduce keyboard error. --> done but the resultant window is not complete - no scroll bar becomes active.
    Problem code:
    set theFiles to (every file of folder addressesFolder) as alias list
    global ABactive, aExists
    property testText : "http://address-parser.com"
    property newGroup : "New Addresses" --> Default group for new address additions
    property aPrefix : ""
    property aFirstName : ""
    property aMiddleName : ""
    property aLastName : ""
    property aSuffix : ""
    property aPosition : ""
    property aDepartment : ""
    property aCompany : ""
    property aCompany2 : ""
    property aStreet : ""
    property aStreet2 : ""
    property aPostbox : ""
    property aPlace : ""
    property aPostPlace : ""
    property aState : ""
    property aZip : ""
    property aPostboxCode : ""
    property aCountry : ""
    property aPhone : ""
    property aPhone2 : ""
    property aMobile : ""
    property aFax : ""
    property aEmail : ""
    property aWebsite : ""
    property aNote : ""
    set newline to ASCII character 10
    -- Select the desired file
    try
        set addressFile to (choose file with prompt "Choose an address file:" of type {"public.text"} without invisibles) as text
        --    set addressFile to (choose file with prompt "Choose an address file:" of type {"public.text"} default location addressesFolder without invisibles) as text
        -- note the data type set for 'addressFile' is 'text'
    on error number -128
        -- User pressed 'Cancel' button
        return
    end try
    set AppleScript's text item delimiters to {":"}
    set fileName to last text item of addressFile
    set AppleScript's text item delimiters to {""}
    (* If there is an error while processing the address file, delay it just long enough to close the file access. Otherwise continue. *)
    set addressFileReference to open for access addressFile
    -- 'addressFileReference' is the 'returned access number'
    -- Check first to see whether the file was created with output from the expected source
    try
        set wholeFile to read addressFileReference as text
        if (offset of testText in wholeFile) is equal to 0 then
            display dialog "File chosen is:" & return & fileName & return & return & "This file does not appear to contain output from the 'http://www.address-parser.com' demo page." buttons {"Cancel"} default button 1 with title "Error!" with icon stop
        end if
    on error number -128
        -- User pressed 'Cancel' button
        close access addressFileReference
        set wholeFile to ""
        return
    end try
    close access addressFileReference
    set wholeFile to ""
    -- Reopen file (need to clarify why EOF error if two read calls made with file open).
    set addressFileReference to open for access addressFile
    try
        set AppleScript's text item delimiters to {""}
        -- Read address file contents in 'addressFileContents' as a list delimited by paragraph and tab.
        set x to paragraphs of (read addressFileReference as text)
        set addressFileContents to {}
        set AppleScript's text item delimiters to tab
        repeat with i from 1 to count x
            set addressFileContents's end to x's item i's text items
        end repeat
        set AppleScript's text item delimiters to {""}
        repeat with i from 1 to count of addressFileContents
            if (item i of addressFileContents) is not {} then
                --Every line must be checked as there is no set order
                if text item 1 of (item i of addressFileContents) is "Prefix= " then ¬
                    set aPrefix to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "First name= " then ¬
                    set aFirstName to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "Middle name= " then ¬
                    set aMiddleName to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "Last name= " then ¬
                    set aLastName to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "Suffix= " then ¬
                    set aSuffix to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "Position= " then ¬
                    set aPosition to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "Department= " then ¬
                    set aDepartment to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "Company= " then ¬
                    set aCompany to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "Company - line 2= " then ¬
                    set aCompany2 to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "Street address= " then ¬
                    set aStreet to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "Street address - line 2= " then ¬
                    set aStreet2 to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "Postbox address= " then ¬
                    set aPostbox to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "Place name= " then ¬
                    set aPlace to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "Post place name= " then ¬
                    set aPostPlace to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "State/Region/Province= " then ¬
                    set aState to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "ZIP/Postal code= " then ¬
                    set aZip to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "Postal code of postbox= " then ¬
                    set aPostboxCode to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "Country= " then ¬
                    set aCountry to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "Phone= " then ¬
                    set aPhone to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "Phone 2= " then ¬
                    set aPhone2 to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "Mobile phone= " then ¬
                    set aMobile to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "Fax= " then ¬
                    set aFax to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "Email= " then ¬
                    set aEmail to text item 2 of (item i of addressFileContents)
                if text item 1 of (item i of addressFileContents) is "Web site= " then ¬
                    set aWebsite to text item 2 of (item i of addressFileContents)
                --Collect unrecognised elements and place them in the 'Note' field
                if text item 1 of (item i of addressFileContents) contains "Unrecognized values:" then
                    set i to i + 1
                    set aNote to "Additional address bits:"
                    repeat with i from i to count of addressFileContents
                        --display dialog "Note text reads:" & return & "aNote:" & tab & "'" & aNote & "'" & return & "Line #:" & tab & i & return & (item i of addressFileContents) as text default button 1 with title "Debug Dialog"
                        if (item i of addressFileContents) is not {} then
                            if item 1 of (item i of addressFileContents) is "" and ¬
                                item 2 of (item i of addressFileContents) is not "" then
                                set aNote to aNote & newline & text item 2 of (item i of addressFileContents)
                            end if
                        end if
                    end repeat
                end if
            end if
        end repeat
    on error errMsg number errNum
        close access addressFileReference
        -- do some sort of error processing here
        display dialog "An error occurred with the following number and description: " & return & errNum & return & errMsg & return & return & "Item " & (i as string) & tab & "'" & (item i of addressFileContents) & "'" with title "Data load section."
        error errMsg number errNum
    end try
    close access addressFileReference
    --Debug dialogs
    --display dialog (item 1 of addressFileContents as text) & return & return & (item 2 of addressFileContents as text) & return & return & (item 3 of addressFileContents as text) & return & return & (item 4 of addressFileContents as text)
    --display dialog "title:" & tab & tab & tab & aPrefix & return & "first name:" & tab & tab & aFirstName & return & "middle name:" & tab & tab & aMiddleName & return & "last name:" & tab & tab & aLastName & return & "suffix:" & tab & tab & tab & aSuffix & return & "job title:" & tab & tab & tab & aPosition & return & "department:" & tab & aDepartment & return & "organization:" & tab & aCompany with title "Just prior to new record insertion:" with icon note
    --check if Contacts application is active
    tell application "System Events"
        if exists application process "Contacts" then
            set ABactive to true
        else
            set ABactive to false
        end if
    end tell
    --display dialog "title:" & tab & tab & tab & aPrefix & return & "first name:" & tab & tab & aFirstName & return & "middle name:" & tab & tab & aMiddleName & return & "last name:" & tab & tab & aLastName & return & "suffix:" & tab & tab & tab & aSuffix & return & "job title:" & tab & tab & tab & aPosition & return & "department:" & tab & aDepartment & return & "organization:" & tab & aCompany with title "Just prior to create new entry:" with icon note
    --create new address entry
    tell application "Contacts"
        try
            --if the aCompany2 variable is filled append its contents to the aCompany variable
            if aCompany2 is equal to "" then
                set thePerson to make new person with properties ¬
                    {title:aPrefix, first name:aFirstName, middle name:aMiddleName, last name:aLastName, suffix:aSuffix, job title:aPosition, department:aDepartment, organization:aCompany}
            else
                set aCompany to aCompany & newline & aCompany2
                set thePerson to make new person with properties ¬
                    {title:aPrefix, first name:aFirstName, middle name:aMiddleName, last name:aLastName, suffix:aSuffix, job title:aPosition, department:aDepartment, organization:aCompany}
            end if
            --set the Company view binary if no First and Last name
            if (first name of thePerson is equal to "") and (last name of thePerson is equal to "") then ¬
                set the company of thePerson to true
            tell thePerson
                if aPhone is not equal to "" then ¬
                    make new phone at end of phones with properties ¬
                        {label:"work", value:aPhone}
                if aPhone2 is not equal to "" then ¬
                    make new phone at end of phones with properties ¬
                        {label:"other", value:aPhone2}
                if aMobile is not equal to "" then ¬
                    make new phone at end of phones with properties ¬
                        {label:"mobile", value:aMobile}
                if aFax is not equal to "" then ¬
                    make new phone at end of phones with properties ¬
                        {label:"fax", value:aFax}
                if aEmail is not equal to "" then ¬
                    make new email at end of emails with properties ¬
                        {label:"Work", value:aEmail}
                if aWebsite is not equal to "" then ¬
                    make new url at end of urls with properties ¬
                        {label:"Work", value:aWebsite}
                if aStreet is not equal to "" then
                    if aStreet2 is equal to "" then
                        make new address at end of addresses with properties ¬
                            {label:"work", street:aStreet, city:aPlace, state:aState, zip:aZip, country:aCountry}
                    else
                        make new address at end of addresses with properties ¬
                            {label:"work", street:aStreet & ", " & aStreet2, city:aPlace, state:aState, zip:aZip, country:aCountry}
                    end if
                end if
                if aPostPlace is equal to "" then set aPostPlace to aPlace
                if aPostbox is not equal to "" then
                    if aPostboxCode is not equal to "" then
                        make new address at end of addresses with properties ¬
                            {label:"postal", street:aPostbox, city:aPostPlace, state:aState, zip:aPostboxCode, country:aCountry}
                    else
                        make new address at end of addresses with properties ¬
                            {label:"postal", street:aPostbox, city:aPlace, state:aState, zip:aZip, country:aCountry}
                    end if
                end if
                if aNote is not equal to "" then set note to aNote
            end tell
            -- place the new entry into a group
            set myGroups to name of every group
            set theGroup to (choose from list myGroups with prompt "Attach to which group?" without multiple selections allowed and empty selection allowed) as text
            --If user selects 'Cancel' button the value of the result variable is 'false'
            if theGroup is not "false" then
                add thePerson to group theGroup
            else
                -- create a default group and place the entry in there; first testing to see whether the default group already exists
                try
                    if group newGroup exists then ¬
                        display dialog "newGroup exists" with icon 1
                    add thePerson to group newGroup
                on error number -1728
                    -- newGroup does not exist so create it
                    display dialog "newGroup does not exist. Make new group with newGroup" with icon 1
                    set theGroup to make new group with properties {name:newGroup}
                    add thePerson to group newGroup
                end try
            end if
            save application "Contacts"
            set selection to (thePerson)
            activate
    --set flag that new address entry was successful by seeking
            if the selection is equal to properties ¬
                {title:aPrefix, first name:aFirstName, ¬
                middle name:aMiddleName, last name:aLastName, ¬
                suffix:aSuffix, job title:aPosition, ¬
                department:aDepartment, organization:aCompany} then ¬
            set aExists to true
        on error errMsg number errNum
            -- do some sort of error processing here
            display dialog "An error occurred with the following number and description: " & return & errNum & return & errMsg with title "Data paste section."
            error errMsg number errNum
        end try
        --if we opened the AB, we'll close it
        if not ABactive then quit
    end tell
    --clear address variables content in case of repeat use
    set aPrefix to ""
    set aFirstName to ""
    set aMiddleName to ""
    set aLastName to ""
    set aSuffix to ""
    set aPosition to ""
    set aDepartment to ""
    set aCompany to ""
    set aCompany2 to ""
    set aStreet to ""
    set aStreet2 to ""
    set aPostbox to ""
    set aPlace to ""
    set aState to ""
    set aZip to ""
    set aPostboxCode to ""
    set aCountry to ""
    set aPhone to ""
    set aPhone2 to ""
    set aMobile to ""
    set aFax to ""
    set aEmail to ""
    set aWebsite to ""
    set aNote to ""
    -- Delete original file if contents have been successfully added
    if aExists then
        try
            tell application "Finder"
                if exists file addressFile then
                    delete file addressFile --moves it to the trash
                end if
            end tell
        on error errMsg number errNum
            display dialog "Inserting new address was successfiul, however an error occurred while deleting the original file:" & return & addressFile buttons {"Cancel"} default button 1 with title "Error!" with icon stop
            display dialog ""
        end try
    end if
    -- End of 'add address' script

    Well, after a few days of restoring my cellphone (The C6-01 I mentioned before), I came to this:
    - After Hard resetting, the Lock Code is still erroneous;
    - After firmware reinstalling, Lock Code is erroneous;
    - Pulling out the battery, leaving the cellphone with no power for several hours, give the same result;
    - Downgrading firmware (previous version) did not fix the problem;
    Interesting thing is, after power on, the cellphone asks for the code lock: entering ANY number, returns "Code Error", and simply goes back to normal operation.
    Everything is working, except I can no use de Lock Code, or any function related to it.
    Of course, is pretty annoying to enter the lock code every time I power-on the cell.

  • Photo Gallery with Mouse over text

    I would like to extended the photo gallery concept and the
    general phot effects so when you mouse over an enlarged image you
    get formatted text drawn from the XML file.
    Like blockbuster does on its site when you mouse over an of
    the DVD images.

    We released the
    Spry
    Tooltip preview to have an early feedback to this feature from
    the community. You can use it experimentally to solve your need.
    Cristian

  • Ejb 2.0 deployment code error with WAS 6.1

    Hi we have recently migrated to WAS 6.1 from 5.1.
    Since then we are facing the below problem.We use ant task to call ejbDeploy.sh to generate deployment code for one of our ejb module.All i did in the ant script was changing the path to ejbdeploy tool from WAS 6.1.However the application is built finally but showing this error in the middle of running the tool.
    If i replace the ejb-jar.xml to version 2.1 it is working fine with no error but as originally the application is coded on ejb 2.0 and here it is showing error.
    I am afraid of changing the dtd version just to avoid this error,also running with the error in the older version would cause any problem in the production later?
    Your help is needed
    Exception:
    {color:#0000ff}o0825.02EJB Deploy configuration directory: /users/users-2/t504625/.eclipse/configurationframework search path: /auto/prod/ver/WAS/610_21/deploytool/itp/plugins
    [exec] org.eclipse.jst.j2ee.commonarchivecore.internal.exception.ResourceLoadException: IWAE0007E Could not load resource "META-INF/ejb-jar.xml" in archive "/vobs/glbtrs01/gmm/build/src/java/temp/AppMessaging.jar"
    [exec] Stack trace of nested exception:
    [exec] org.eclipse.emf.common.util.WrappedException: java.net.ConnectException: Connection timed out
    [exec] at org.eclipse.wst.common.internal.emf.resource.EMF2SAXRenderer.doLoad(EMF2SAXRenderer.java:97)
    [exec] at org.eclipse.wst.common.internal.emf.resource.TranslatorResourceImpl.basicDoLoad(TranslatorResourceImpl.java:142)
    [exec] at org.eclipse.wst.common.internal.emf.resource.CompatibilityXMIResourceImpl.doLoad(CompatibilityXMIResourceImpl.java:173)
    [exec] at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:1094)
    [exec] at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:900)
    [exec] at org.eclipse.wst.common.internal.emf.resource.CompatibilityXMIResourceImpl.load(CompatibilityXMIResourceImpl.java:259)
    [exec] at org.eclipse.wst.common.internal.emf.resource.TranslatorResourceImpl.load(TranslatorResourceImpl.java:388)
    [exec] at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoad(ResourceSetImpl.java:249)
    [exec] at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoadHelper(ResourceSetImpl.java:264)
    [exec] at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getResource(ResourceSetImpl.java:390)
    [exec] at org.eclipse.jst.j2ee.commonarchivecore.internal.strategy.LoadStrategyImpl.getMofResource(LoadStrategyImpl.java:347)
    [exec] at org.eclipse.jst.j2ee.commonarchivecore.internal.impl.ArchiveImpl.getMofResource(ArchiveImpl.java:731)
    [exec] at org.eclipse.jst.j2ee.commonarchivecore.internal.impl.ModuleFileImpl.getDeploymentDescriptorResource(ModuleFileImpl.java:61)
    [exec] at com.ibm.etools.ejbdeploy.batch.plugin.BatchExtension.preprocessArchives(BatchExtension.java:3681)
    [exec] at com.ibm.etools.ejbdeploy.batch.plugin.BatchExtension.run(BatchExtension.java:340)
    [exec] at org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:78)
    [exec] at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:92)
    [exec] at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:68)
    [exec] at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:400)
    [exec] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    [exec] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    [exec] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    [exec] at java.lang.reflect.Method.invoke(Method.java:585)
    [exec] at com.ibm.etools.ejbdeploy.batch.impl.BootLoaderLoader.run(BootLoaderLoader.java:476)
    [exec] at com.ibm.etools.ejbdeploy.batch.impl.BatchDeploy.execute(BatchDeploy.java:101)
    [exec] at com.ibm.etools.ejbdeploy.EJBDeploy.execute(EJBDeploy.java:106)
    [exec] at com.ibm.etools.ejbdeploy.EJBDeploy.main(EJBDeploy.java:336)
    [exec] Caused by: java.net.ConnectException: Connection timed out
    [exec] at java.net.PlainSocketImpl.socketConnect(Native Method)
    [exec] at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333)
    [exec] at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195)
    [exec] at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182)
    [exec] at java.net.Socket.connect(Socket.java:507)
    [exec] at java.net.Socket.connect(Socket.java:457)
    [exec] at sun.net.NetworkClient.doConnect(NetworkClient.java:157)
    [exec] at sun.net.www.http.HttpClient.openServer(HttpClient.java:365)
    [exec] at sun.net.www.http.HttpClient.openServer(HttpClient.java:477)
    [exec] at sun.net.www.http.HttpClient.<init>(HttpClient.java:214)
    [exec] at sun.net.www.http.HttpClient.New(HttpClient.java:287)
    [exec] at sun.net.www.http.HttpClient.New(HttpClient.java:299)
    [exec] at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:792)
    [exec] at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:744)
    [exec] at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:669)
    [exec] at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:913)
    [exec] at org.apache.xerces.impl.XMLEntityManager.setupCurrentEntity(Unknown Source)
    [exec] at org.apache.xerces.impl.XMLEntityManager.startEntity(Unknown Source)
    [exec] at org.apache.xerces.impl.XMLEntityManager.startDTDEntity(Unknown Source)
    [exec] at org.apache.xerces.impl.XMLDTDScannerImpl.setInputSource(Unknown Source)
    [exec] at org.apache.xerces.impl.XMLDocumentScannerImpl$DTDDispatcher.dispatch(Unknown Source)
    [exec] at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
    [exec] at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
    [exec] at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
    [exec] at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
    [exec] at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
    [exec] at org.eclipse.wst.common.internal.emf.resource.EMF2SAXRenderer.doLoad(EMF2SAXRenderer.java:93)
    [exec] ... 26 more {color}

    I am sure all the setup is coorect.
    i even tried the same script with WAS 5.1 ejbDeploy.sh tool and did not face this problem.
    This is what i tried again in WAS 6.1 but with the same result.
    We had two ejb module.
    I replaced dtd to version 2.1 in one module and left the other one with the 2.0
    Then when the ant scripts execute the task ejbDeploy.sh
    for module 1 with dtd 2.1 it shows WAS/deploytool/ipt/ejbdeploy.options not found error and stays for a second and then started building tha module 1 no exception is thrown and then shows the same not found error for module 2 with dtd 2.0 and stays forever until the connection timeout exception is thrown and then started building the module.
    I don't know the cause for the timeout exception when only DTD 2.0 is used.
    Please help.

  • Music with mouse over

    How do i have a sound snippet play when i hover over a piece of text or an image ? I have tried adding numerous pieces of code but I do not seem to be able to get an mp3 sound to play.
    Thanks,Michael

    That's right.
    Start Personal Webserver (I use the name from the past when I had a web-, FTP-, mail- and Listserver on my Mac LC 14 years ago) and serve.
    It's in System Preferences > Share
    With iWeb 08 it is more cumbersome because you publish the whole folder again and again even when only one character on a page is changed.
    One reason to upgrade to iWeb 09.
    Anyway, you can either publish to the Sites folder in your home Directory or to the folder which is the root of the webserver.
    /Library/Webserver/Documents/
    I publish local to see how a page looks and behave. Then I move the page to the Site I publish remotely.
    With iWeb 09 you can do the same in one go. Change to publish to folder and then change back to FTP and/or MobileMe. One Site with three option to publish. iWeb remembers the settings.
    Besides the convenience of publishing with iWeb 09, I also have my domainname configured to my Mac at home.
    How you configure your webserver is in the Apache manual.
    http://localhost/manual/

  • Dock keeps restarting with mouse over

    My dock keeps restarting when the mouse is over it. I've searched the web and i've found a lot of posts about this issue, and with a lot of sugestions, but none of them had solved this problem.
    Anyone with the same problem, that had found a solution?
    Thanks in advance.
    Best regards

    Hello fsf:
    Welcome to Apple discussions.
    Try trashing the preference file and restarting (com.apple.dock.plist). You will have to reenter your personal preferences.
    Barry

  • Scroll error with mouse wheel [SOLVED]

    thought this only happened in firefox, but it happens in opera and konqueror
    i did a fresh install of arch and it is updated. installed xorg and kde. i have used the firefox package from arch as well as installing from mozilla.com itself, same issue in firefox, but like i said it happens in other browsers and file managers
    if i scroll down (towards me) its fine, but if i scroll up, i get the right click popup menu. in konq it is a little different as it places whatever i copied into the clipboard into the address bar as a web page
    relevant parts of my xorg.conf
    Section "InputDevice"
    # Identifier and driver
    Identifier "Mouse1"
    Driver "mouse"
    Option "Protocol" "IMPS/2" # IntelliMouse PS/2
    Option "Device" "/dev/psaux"
    Option "ZAxisMapping" "4 5"
    # Option "Emulate3Buttons"
    # Option "Emulate3Timeout" "50"
    this didn't use to happen, but i cant remember when it started and what was updated when it did. also i do not notice this on other distros. i have also enabled emulate3buttons and added to zaxismapping to 4 5 6 7, no change. any ideas? it is a standard logitech wheel mouse.

    ok so i modified my xorg.conf to include the following
    Identifier "Mouse1"
    Driver "mouse"
    Option "Protocol" "IMPS/2"
    Option "Device" "/dev/psaux"
    Option "ButtonMapping" "1 2 3 4 5"
    Option "ZAxisMapping "4 5"
    i added the buttonmapping line from pclinuxos where my mouse works fine, but it was originally 1 2 3 6 7, i changed it to what is above to see if that worked, it did not. i have also tried explorerps/2, /dev/input/mouse, and 4 5 6 7 for zaxismapping and enabled and disabled emulate3buttons...all with no change
    i have run xev and it seems that when i scroll up i get a buttonpress event on button 3 and button 4 with a release event for button 4
    so from that it appears that when i scroll up it is also executing a right mouse click (button 3)
    any ideas?

  • Code Error with Case Statement

    Hi everyone,
    I'm new to PL/SQL and APEX and I'm trying to get this code to work. It is supposed to insert an sysdate if the named fields are changed and then update the fields.
    This is the code:
    BEGIN
    SELECT ATS_CLS_NAME, ATS_CEL_NAME, ATS_END_DATE,
    CASE
    WHEN
    ATS_CLS_NAME <> :P6_ATS_CLS_NAME
    AND ATS_CLS_NAME <> :P6_ATS_CEL_NAME
    AND ATS_END_DATE is Null
    THEN
    UPDATE ATS_ALLOCATION
    SET
    ATS_ALLOCATION_ID = :P6_ATS_ALLOCATION_ID,
    ATS_START_DATE = :P6_ATS_START_DATE,
    ATS_END_DATE = SYSDATE,
    ATS_CLS_NAME = :P6_ATS_CLS_NAME,
    ATS_CEL_NAME = :P6_ATS_CEL_NAME,
    ATS_EMP_ID = :P6_EMP_EMP_ID
    ELSE
    UPDATE ATS_ALLOCATION
    SET
    ATS_ATS_ALLOCATION = :P6_ATS_ALLOCATION,
    ATS_START_DATE = :P6_ATS_START_DATE,
    ATS_END_DATE = :P6_ATS_END_DATE,
    ATS_CLS_NAME = :P6_ATS_CLS_NAME,
    ATS_CEL_NAME = :P6_ATS_CEL_NAME,
    ATS_EMP_ID = :P6_EMP_EMP_ID
    FROM ATS_ALLOCATION
    END CASE;
    END;
    And I get this error:
    1 error has occurred
    ORA-06550: line 12, column 7: PL/SQL: ORA-00936: missing expression ORA-06550: line 5, column 1: PL/SQL: SQL Statement ignored

    BEGIN
    UPDATE ATS_ALLOCATION
    SET
    ATS_ATS_ALLOCATION = :P6_ATS_ALLOCATION,
    ATS_START_DATE = :P6_ATS_START_DATE,
    ATS_END_DATE = CASE
         WHEN ATS_CLS_NAME <> :P6_ATS_CLS_NAME
         AND ATS_CLS_NAME <> :P6_ATS_CEL_NAME
         AND ATS_END_DATE is Null
         THEN SYSDATE
         ELSE :P6_ATS_END_DATE
    END,
    ATS_CLS_NAME = :P6_ATS_CLS_NAME,
    ATS_CEL_NAME = :P6_ATS_CEL_NAME,
    ATS_EMP_ID = :P6_EMP_EMP_ID
    END;
    1 error has occurred
    ORA-06550: line 18, column 3: PL/SQL: ORA-00933: SQL command not properly ended ORA-06550: line 4, column 1: PL/SQL: SQL Statement ignored ORA-06550: line 21, column 21: PLS-00103: Encountered the symbol "end-of-file" when expecting one of the following: begin case declare end exception exit for goto if loop mod null pragma raise return select update while with

  • Error with mouse event function

    Hi,
         I have inserted two keyframes in the timeline, then i included scripts on each keyframe. The script in first keyframe is following:
    stop();
    var mc:MovieClip = new MovieClip();
    mc.graphics.beginFill(0xFF0000);
    mc.graphics.drawRect(0,0,300,20);
    mc.graphics.endFill();
    addChild(mc);
    mc.addEventListener(MouseEvent.CLICK,clicked)
    function clicked(){
        gotoAndPlay(2);
    The script in the second keyframe is following:
    var mc1:MovieClip = new MovieClip();
    mc1.graphics.beginFill(0xFF00FF);
    mc1.graphics.drawRect(0,0,300,20);
    mc1.graphics.endFill();
    addChild(mc1);
    The error which was reported while compiling is defined as follows:
    When i click on the movieclip 'mc' created in the first frame, an error like "ArgumentError: Error #1063: Argument count mismatch on gallery_fla::MainTimeline/clicked(). Expected 0, got 1."  is showing. Actually i need to go to the second frame while clicking on the movieclip on first keyframe.
    Regards,
          Sreelash

    Use following:
    stop();
    var mc:MovieClip = new MovieClip();
    mc.graphics.beginFill(0xFF0000);
    mc.graphics.drawRect(0,0,300,20);
    mc.graphics.endFill();
    addChild(mc);
    mc.addEventListener(MouseEvent.CLICK,clicked)
    function clicked(evnt:MouseEvent)
         gotoAndPlay(2);
    When we use a function as an event listener it should catch the event as an argument. that is why you are getting this error.

Maybe you are looking for