File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Java Micro Edition and the fly likes limit login attempts Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Mobile » Java Micro Edition
Bookmark "limit login attempts" Watch "limit login attempts" New topic

limit login attempts

dan sidebottom

Joined: Aug 15, 2010
Posts: 1
hi how do i change this code to limit user attempts to 3?

public void validateUser(String name, String password) {
if (name.equals("admin") && password.equals("letmein")) {
} else {
public void tryAgain() {
Alert error = new Alert("Login Incorrect", "Please try again", null, AlertType.ERROR);

Many thanks
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 17417

Welcome to the JavaRanch, Dan.

Question #1: Is this supposed to have anything at all to do with Java Mobile Edition?

Question #2: What sort of system is this code supposed to be part of? Is it web-based? An applet? Servlet? Stand-alone application?

An IDE is no substitute for an Intelligent Developer.
I agree. Here's the link:
subject: limit login attempts
It's not a secret anymore!