Back End Web Browser Interaction?

Please support our C++ advertiser: Intel Parallel Studio Home
Reply

Join Date: May 2009
Posts: 2
Reputation: spectrum6125 is an unknown quantity at this point 
Solved Threads: 0
spectrum6125 spectrum6125 is offline Offline
Newbie Poster

Back End Web Browser Interaction?

 
0
  #1
May 13th, 2009
Alright so I'm working with a program that works with various email programs and I'd like to use it to automate the login process. I know I can open a browser using
ShellExecute(NULL, "open", "https://various.email.com/", NULL, NULL, SW_SHOWNORMAL);
but how would I actually parse the login/password strings into the text fields of the browser?
Reply With Quote Quick reply to this message  
Join Date: Oct 2008
Posts: 122
Reputation: Liszt is an unknown quantity at this point 
Solved Threads: 6
Liszt Liszt is offline Offline
Junior Poster

Re: Back End Web Browser Interaction?

 
-1
  #2
May 13th, 2009
Just an alternative on the way to open browsers:
  1. String^ myURL = "http://www.google.com";
  2.  
  3. System::Diagnostics::Process::Start("iexplore.exe", myURL );

I beleive what you have to do is to extract the login and password as two strings and then create a new string (myURL) like this:
  1. String^ myURL = "http://www.google.com";
  2. String^ mylogin = "abc";
  3. String^ myPassword = "def"
  4.  
  5. //New myURL
  6. myURL = myURL + "/" + myUser + "/" + myPassword;

Hope it helps!


Originally Posted by spectrum6125 View Post
Alright so I'm working with a program that works with various email programs and I'd like to use it to automate the login process. I know I can open a browser using
ShellExecute(NULL, "open", "https://various.email.com/", NULL, NULL, SW_SHOWNORMAL);
but how would I actually parse the login/password strings into the text fields of the browser?
Last edited by Liszt; May 13th, 2009 at 10:39 pm.
Reply With Quote Quick reply to this message  
Join Date: Nov 2008
Posts: 977
Reputation: MosaicFuneral is just really nice MosaicFuneral is just really nice MosaicFuneral is just really nice MosaicFuneral is just really nice MosaicFuneral is just really nice 
Solved Threads: 92
MosaicFuneral's Avatar
MosaicFuneral MosaicFuneral is offline Offline
Posting Shark

Re: Back End Web Browser Interaction?

 
0
  #3
May 13th, 2009
Was any of that C++, Liszt?
"Jedenfalls bin ich überzeugt, daß der Alte nicht würfelt."
"I became very sensitive to what will happen to all this and all of us." -Two geniuses named Albert
Reply With Quote Quick reply to this message  
Join Date: May 2009
Posts: 2
Reputation: spectrum6125 is an unknown quantity at this point 
Solved Threads: 0
spectrum6125 spectrum6125 is offline Offline
Newbie Poster

Re: Back End Web Browser Interaction?

 
0
  #4
May 14th, 2009
Thank you for the input Liszt but parsing the login information into the URL won't work for me, what I essentially need is a way to automate the entering of text into the login/password text fields.
Reply With Quote Quick reply to this message  
Join Date: Mar 2008
Posts: 678
Reputation: Sky Diploma is a splendid one to behold Sky Diploma is a splendid one to behold Sky Diploma is a splendid one to behold Sky Diploma is a splendid one to behold Sky Diploma is a splendid one to behold Sky Diploma is a splendid one to behold 
Solved Threads: 101
Sky Diploma's Avatar
Sky Diploma Sky Diploma is offline Offline
Practically a Master Poster

Re: Back End Web Browser Interaction?

 
0
  #5
May 14th, 2009
Well when the page loads up. You SHOULD CHECK OUT THE source and see for the names of the forms.

then you can write something like this

"http://www.some.some/login.php?FORMNAME1=Username&FORMNAME2=Password

Replace formname with the actual form names in the source and User Name and password with your user names
1. Please Mark Your Thread as Solved After Getting Your Answers.
2. Please Use CODE TAGS .
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:


Thread Tools Search this Thread



Tag cloud for C++
About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC