I want to make: when i click a button after I've given some input it checks & if successful it opens a new window/page i.e I want to create a link....till now I've done
JOptionPane.showMessageDialog(null,"you are not allowed");
}
}
}
here in the place of "login successful" i want to put somthing that will open a window to be specific I want open a "xyz" web application. for eg: "http://localhost:8080/xyz"......hope I've made myself clear....please suggest..thanks
As masijade said, you can do that with an ActionListener, however I have to wonder why you are writing a Java program just for a login and then opening a web application. Why not simply login in to the web application?
actually i want only "one person"/admin to enter a specific folder inside the application not the whole application as you said....could someone tip me some details about ActionListener....i'm bit confused!
I want to pass this URL
"http://localhost:8080/xyz/admin" as a parameter when the user clicks OK or enters the password in the JoptionPane.......is it possible with ActionListener.....how?
ps: how can I make both the username/password be taken from ONE dialog box? (as you can see i'm using 2boxes)
Last edited by apontutul; Aug 19th, 2007 at 7:03 am.
Read the API for JOptionPane. I assume you're letting him enter a URL, in that case you already have the URL, you simply need to capture the return value of the JOptionPane method. As I said, read the API for that (and the tutorial), it explains it completely.
could'nt understand what you meant by that.
the user enters id/pw (both "admin")...if he enters correctly he will be given the access to the "admin" folder of the web application. the user does'nt enters any URL!!!....is there any tool other than JoptionPane that will make matters easier?
What do you mean "you want to pass it as a parameter". Explain, without reference to URLs, JOptionPanes, Parameter Passing, or anything else technical, what it is, exactly that you want to accomplish.
Last edited by masijade; Aug 20th, 2007 at 4:51 am. Reason: typo
Either the thread starter or a moderator has marked this thread as solved. You can most likely trust the responses and answers given. There is most likely no reason for any further responses to be posted here. If you have a related question, please start a new thread in this forum instead.
This thread is more than three months old
No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.