Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: ASP.NET
I want to open website login using windows form application.
Posted 30-May-12 22:22pm
Comments
Richard MacCutchan at 31-May-12 4:26am
   
And what is your problem?
sanjeevjinfotel at 31-May-12 4:31am
   
i want to create application that will automatically login my attandence website.
Richard MacCutchan at 31-May-12 4:44am
   
I understand that, but you have not said which part of it you are having problems with.
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

You are talking about website automation. If your windows forms has a web browser control in it you could do website actions (i.e. button clicks, read textboxes) quite easily.
 
Here is a good reference site for more detail:
http://social.msdn.microsoft.com/Forums/en-US/vbgeneral/thread/23dfc3f9-3274-4929-8dc5-9ba543f4911d[^]
  Permalink  
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

Create a Windows Application
 
Add WebBrowser Control
Write Code to Navigate Site
public bool isrun;
        private void Form1_Load(object sender, EventArgs e)
        {
            webBrowser1.Url = new Uri("http://www.yourwebsite.com");
        }
 
 
after this add a event DocumentCompleted
which occurs where page completely loaded
 
        private void webBrowser1_DocumentCompleted(object sender, WebBrowserDocumentCompletedEventArgs e)
        {
        if(!isrun)
        {
            webBrowser1.Document.GetElementById("login_name").InnerText = "uid";
            webBrowser1.Document.GetElementById("passwd").InnerText = "pwd";
            webBrowser1.Document.GetElementById("buttonid_login").InvokeMember("click");      
           isrun=true;
        }
 
}
 

 

  Permalink  
Comments
sanjeevbaadsah at 31-May-12 4:58am
   
thanks a lot.:):)
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 3

You should use Web Browser Control In Windows Application
Thanks
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 693
1 George Jonsson 345
2 BillWoodruff 337
3 PIEBALDconsult 280
4 Sergey Alexandrovich Kryukov 244
0 Sergey Alexandrovich Kryukov 10,744
1 Maciej Los 5,474
2 OriginalGriff 5,352
3 CPallini 3,819
4 BillWoodruff 3,556


Advertise | Privacy | Mobile
Web02 | 2.8.141030.1 | Last Updated 31 May 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100