• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

show user credentials in target jsp which all are from swing form

siva perumal
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

I have to open target jsp in iexploere along with user credentials which are from swing application by clicking submit in swing .

I need to show the user credentials in my target jsp Which user credentials are coming from swing login form .

I have used java.net URL to send the HTTP request to my target jsp from my swing window . this swing window has user name , password fields , Actually HTTP request are sending fine i am able to print those user name in my target jsp . but i unable to open target jsp in internet explorer along with user name .

here my code for ref:

String data = URLEncoder.encode("username", "UTF-8") + "=" + URLEncoder.encode("hi", "UTF-8");
data += "&" + URLEncoder.encode("password", "UTF-8") + "=" + URLEncoder.encode("hru", "UTF-8");

// Send data

URL url = new URL("");
URLConnection conn = url.openConnection();
OutputStreamWriter wr = new OutputStreamWriter(conn.getOutputStream());

// Get the response
BufferedReader rd = new BufferedReader(new InputStreamReader(conn.getInputStream()));
String line;
while ((line = rd.readLine()) != null) {


rt.exec("C:/Program Files/Internet Explorer/IEXPLORE.EXE");


thanks in advance
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic