CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 4 of 4
  1. #1
    Join Date
    Feb 2000
    Posts
    11

    Swing lost focus event problem in browser

    I use a lost focus event for data validation for a JTextField in my applet -- a message box pops up on lost focus if invalid data input is detected. While this works fine from IDE (in my case, Visual Cafe), if I try it from the browser however, the same message box pops up many times each time the lost focus happens with invalid input. I already checked and handled the tempery event from the lost focus routine and it works just as expected from the applet viewer. Does anyone has a solution to this problem? Or has someone heard of this before?

    Thanks.


  2. #2
    Join Date
    Sep 1999
    Location
    Madurai , TamilNadu , INDIA
    Posts
    1,024

    Re: Swing lost focus event problem in browser


  3. #3
    Join Date
    Feb 2000
    Posts
    11

    Re: Swing lost focus event problem in browser

    Thanks Poochi,

    Yes, I did handled the temporary event -- test to see if it is temporary and do nothing if it is. I don't have problem with that. My problem is that the lost focus event get called more times when I run the applet in web server/browser environment, while it works just fine from applet viewer or other IDEs. Every time I test it from the brower, the same message box I created pops up 2 or 4 times when focus lost event got fired with an invalid input in the testing JTextField.

    Any ideas?

    Thanks again.

    Lifeng


  4. #4
    Join Date
    Sep 1999
    Location
    Madurai , TamilNadu , INDIA
    Posts
    1,024

    Re: Swing lost focus event problem in browser


    Can you post a simple and compilable code ?


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured