Robot Class

Robot Class is available under java.awt package. Using this Robot Class we can simulate keyboard events in Selenium.


import java.awt.AWTException;
import java.awt.Robot;

import com.thoughtworks.selenium.DefaultSelenium;
import com.thoughtworks.selenium.Selenium;

public class AutomateKeyboard

{

DefaultSelenium selenium = new DefaultSelenium("localhost",4444,"*firefox","http://");
  
    Robot r =null;

public void GmailLoginCheck()  {

selenium.start();

 selenium.open("http://www.gmail.com");
selenium.type("xxxxxxxxxx", "xxxxxxxxxxxxxxxx");
selenium.type("xxxxxxxxxxxxxxxxx", "xxxxxxxxxxxxxxxxxxxxxxx");

r.keyPress(java.awt.event.KeyEvent.VK_ENTER);  // Here we are using robot class

}

public static void main(String args[]){

 

AutomateKeyboard   automate  = new AutomateKeyboard();

automate.GmaillLoginCheck();

}

}



50 comments:

  1. Excellent post!!! Selenium automation testing tool makes your software validation process lot simpler. Keep on updating your blog with such awesome information. Selenium Training in Chennai | Selenium Course in Chennai | Selenium training institute in Chennai

    ReplyDelete
    Replies
    1. I have read your blog its very attractive and impressive. I like it your blog.

      Java Training in Chennai Core Java Training in Chennai Core Java Training in Chennai

      Java Online Training Java Training in Chennai Core Java 8 Training in Chennai Core Java 8 Training in Chennai JavaEE Training in Chennai Java EE Training in Chennai

      Delete
    2. Hibernate Online Training Hibernate Online Training Hibernate Training in Chennai Hibernate Training in Chennai Java Online Training Java Online Training

      Hibernate Training Institutes in ChennaiHibernate Training Institutes in Chennai Java Online Training Java Online Training Java Online Training Java Online Training

      Delete
    3. Hibernate Online Training Hibernate Online Training Hibernate Training in Chennai Hibernate Training in Chennai Java Online Training Java Online Training

      Hibernate Training Institutes in ChennaiHibernate Training Institutes in Chennai Java Online Training Java Online Training Java Online Training Java Online Training

      Delete
  2. Hi, I wish to be a regular contributor of your blog. I have read your blog. Your information is really useful for us. I did Software Testing Training in Chennai at Fita training and placement academy which offer best Testing Training in Chennai with years of experienced professionals. This is really useful for me to make a bright career.

    ReplyDelete
  3. if possible share with us...Very useful information is providing by ur blog.here is a way to find Oracle Training In Chennai

    ReplyDelete
  4. i wondered keep share this sites .if anyone wants realtime training Greens technolog chennai in Adyar visit this blog..performance tuning training In Chennai and more Oracle Training In Chennai

    ReplyDelete
  5. once again sharing this informative blog .Datastage training In Chennai It uses a graphical notation to construct data integration solutions and is available in various versions may visit greens technology chennai in adyar Greens Technologys Training In Chennai

    ReplyDelete
  6. i gain the knowledge of Java programs easy to add functionalities play online games, chating with others and industry oriented coaching available from greens technology chennai in Adyar may visit.Core java training In Chennai

    ReplyDelete
  7. I have read your blog and I got very useful and knowledgeable information from your blog. It’s really a very nice article Greens Technologies Training In Chennai

    ReplyDelete
  8. fantastic presentation .We are charging very competitive in the market which helps to bring more oracle professionals into this market. may update this blog . Oracle training In Chennai which No1:Greens Technologies In Chennai

    ReplyDelete
  9. Excellent post, I agree with you 100%! I’m always scouring the oracle for new information and learning whatever I can, and in doing so I sometimes leave comments on blogs.Oracle Training In Chennai

    ReplyDelete
  10. Oracle DBA Training in Chennai
    Thanks for sharing this informative blog. I did Oracle DBA Certification in Greens Technology at Adyar. This is really useful for me to make a bright career..

    ReplyDelete
  11. Whatever we gathered information from the blogs, we should implement that in practically then only we can understand that exact thing clearly, but it’s no need to do it, because you have explained the concepts very well. It was crystal clear, keep sharing..
    Websphere Training in Chennai

    ReplyDelete
  12. Data warehousing Training in Chennai
    I am reading your post from the beginning, it was so interesting to read & I feel thanks to you for posting such a good blog, keep updates regularly..

    ReplyDelete
  13. Selenium Training in Chennai
    Wonderful blog.. Thanks for sharing informative blog.. its very useful to me..

    ReplyDelete
  14. Oracle Training in chennai
    Thanks for sharing such a great information..Its really nice and informative.

    ReplyDelete
  15. I have read your blog and i got a very useful and knowledgeable information from your blog.You have done a great job.
    SAP Training in Chennai

    ReplyDelete
  16. This information is impressive..I am inspired with your post writing style & how continuously you describe this topic. After reading your post,thanks
    for taking the time to discuss this, I feel happy about it and I love learning more about this topic
    Android Training In Chennai In Chennai

    ReplyDelete
  17. Pretty article! I found some useful information in your blog, it was awesome to read,thanks for sharing this great content to my vision, keep sharing..
    Unix Training In Chennai

    ReplyDelete
  18. I found some useful information in your blog, it was awesome to read,
    thanks for sharing this great content to my vision, keep sharing..
    SalesForce Training in Chennai

    ReplyDelete
  19. There are lots of information about latest technology and how to get trained in them, like Best Hadoop Training In Chennai have spread around the web, but this is a unique one according to me. The strategy you have updated here will make me to get trained in future technologies Hadoop Training in Chennai By the way you are running a great blog. Thanks for sharing this blogs..

    ReplyDelete
  20. This blog is impressive and informative.It clearly explains about the concept and its techniques.Thanks for sharing this information.Please update this type of
    information
    Salesforce Training in Chennai

    ReplyDelete
  21. We are providing quality Java course training with low price in Chennai, Bangalore and Hyderabad. Java technology’s versatility, efficiency, platform portability, and security make it the ideal technology for network computing.

    java training in chennai

    ReplyDelete
  22. We are providing quality Java course training with low price in Chennai, Bangalore and Hyderabad. Java technology’s versatility, efficiency, platform portability, and security make it the ideal technology for network computing.


    java training in chennai

    ReplyDelete
  23. As disussed above software testing is one of the important field in detecting the bugs. In Software testing selenium training institute in Chennai we are enabled to identify the errors with selenium course and can match the actual results with that of expected results.

    ReplyDelete
  24. As disussed above software testing is one of the important field in detecting the bugs. In Software testing selenium training institute in Chennai we are enabled to identify the errors with selenium course and can match the actual results with that of expected results.

    ReplyDelete
  25. It's worth guide, do more post like this one :)
    Regards,
    Software training

    ReplyDelete
  26. We provide all registered candidate’s training based on the real-world and current market trends, and requirements.
    Android Training in Chennai |
    Android Training in Sholiganallur |
    Android Training in Tambaram |
    Android Training in Chennai |

    ReplyDelete
  27. Thanks for the awesome share
    We at Colan Infotech Private Limited best web design company in chennai,is Situated in US and India,
    will provide you best service in qa testing services
    Design Services and Colan Infotech has a group of exceedingly dedicated, inventive and creative experts with an energy for delivering exciting ,
    helpful and stylish Web and Mobile Applications, We are one of the best software testing services company
    and of course we stepped in bangalore too we are best qa and testing services
    can provide quality assurance and testing services,
    we are the best among the software testing company india

    ReplyDelete
  28. Thanks for the awesome share
    We at Colan Infotech Private Limited best web design company in chennai,is Situated in US and India,
    will provide you best service in qa testing services
    Design Services and Colan Infotech has a group of exceedingly dedicated, inventive and creative experts with an energy for delivering exciting ,
    helpful and stylish Web and Mobile Applications, We are one of the best software testing services company
    and of course we stepped in bangalore too we are best qa and testing services
    can provide quality assurance and testing services,
    we are the best among the software testing company india

    ReplyDelete
  29. The information you have given here are most worthy for me. I have implemented in my training program as well, thanks for sharing. Java Training in Chennai

    ReplyDelete
  30. Thank you for taking the time to provide us with your valuable information. We strive to provide our candidates with excellent care and we take your comments to heart.As always, we appreciate your confidence and trust in us.
    Java Training in Chennai

    ReplyDelete
  31. This is excellent information. It is amazing and wonderful to visit your site.Thanks for sharng this information,this is useful to me...
    Android training in chennai
    Ios training in chennai

    ReplyDelete
  32. Really it was an awesome article...very interesting to read..You have provided an nice article....Thanks for sharing..
    Web Design Company
    Web Development Company

    ReplyDelete


  33. Thanks for posting useful information.You have provided an nice article, Thank you very much for this one. And i hope this will be useful for many people.. and i am waiting for your next post keep on updating these kinds of knowledgeable things...
    Web Design Development Company

    ReplyDelete
  34. I just see the post i am so happy the post of information's.So I have really enjoyed and reading your blogs for these posts.Any way I’ll be subscribing to your feed and I hope you post again soon.
    Websphere Training in Chennai

    ReplyDelete
  35. Nice blog thanks for providing such a great information selenium Jobs in hyderabad

    ReplyDelete
  36. This article is so informatic and it really helped me to know more about the Selenium Testing. This selenium article helps the beginners to learn the best training course. So keep updating the content regularly.
    Selenium Training in Chennai | Best Selenium Training institute in Chennai | Selenium Course in Chennai

    ReplyDelete
  37. This comment has been removed by the author.

    ReplyDelete
  38. Hello Admin,
    I really enjoyed while reading your article, the information you have mentioned in this post was damn good. Keep sharing your blog with updated and useful information.

    Selenium Training in Bangalore

    ReplyDelete
  39. Incredible articles, as a matter of first importance Thanks for composing such stunning Post! Prior I felt that posts are the main most imperative thing on any blog.


    Hadoop Training in Bangalore

    ReplyDelete

  40. I have seen lot blogs and Information on othersites But in this Java Blog Information is very useful thanks for sharing it........

    ReplyDelete
  41. Wonderful blog.. Thanks for sharing informative blog.. its very useful to me..

    Web Development Houston

    ReplyDelete
  42. Very nice post here and thanks for it .I always like and such a super contents of these post.Excellent and very cool idea and great content of different kinds of the valuable information's.
    PEGA Training in Chennai

    ReplyDelete
  43. Besant Technologies is the best training institute in chennai.We are known for our practical approach towards trainings that enable students to gain real-time exposure on competitive technologies. Trainings are offered by professionals to give a real corporate exposure.So join this institute and create your own career. Java Training in Chennai |
    Dot Net Training in Chennai

    ReplyDelete