• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Devaka Cooray
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Jeanne Boyarsky
  • Tim Cooke
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Tim Moores
  • Mikalai Zaikin
  • Carey Brown
Bartenders:

Can someone please help

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello everyone.. I am having a little problem and I can't quite figure it out

I am trying to make a simple GUI which asks for username/password.. sends that information to check against database.. if its true come back .. clear the contents of the frame and start building the client side app ( I am not quite sure how to do this part ). Do I ask for the username/password in a dialog and then full client app in a frame? or have username/password in a frame and then dialog for full client app?

Here is what I have...

ANd this is the LoginWindow() code



Feedback appreciated
 
Marshal
Posts: 78691
374
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Welcome to the Ranch
You might have got a quicker reply with a more informative thread title.

A dialog sounds a good way to enter a password. Remember you may have to encrypt the password if you are passing it across a network.

Other people will have different opinions.
 
Bartender
Posts: 1104
10
Netbeans IDE Java Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
yah, JDialog is the right fit for username/password. You can initially just launch the dialog and check the credentials. If the credentials are not good or if there are validation errors, user can return to the dialog to re-enter. If login is successful, you just call dialog.dispose() and build a frame and show it.
 
When it is used for evil, then watch out! When it is used for good, then things are much nicer. Like this tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic