1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

How to simulate typing?

Discussion in 'C, C++, C#' started by kytro360, Sep 5, 2011.

  1. kytro360

    kytro360 Power Member

    Joined:
    Jan 12, 2010
    Messages:
    703
    Likes Received:
    732
    How would I simulate typing in my bot?I have a listbox where it has a text. How would I post this text on a form to page but instead of just a simple: webBrowser1.Document.GetElementById ("ID").SetAttribute ("value", textBox1.Text);How can I make it seem like its actually typing the text. Im trying to do this in httpwebrequests so it would be great if you teach me or post your code with this in mind.Thanks :)
     
  2. machines-in-motion

    machines-in-motion Junior Member

    Joined:
    Aug 11, 2010
    Messages:
    129
    Likes Received:
    46
    Occupation:
    Engineer
    Location:
    Here and there
    I use Autohotkey (http://nullrefer.com/?http://www.autohotkey.com) for all of that sort of automation, but I don't know it it matters if you're using httpwebrequests. Unless it's a special flash text box, the site has no way of knowing if you're typing or setting the content (your computer only sends the data after you submit the form)
     
  3. ~divinci

    ~divinci Registered Member

    Joined:
    Sep 23, 2009
    Messages:
    51
    Likes Received:
    11
    Occupation:
    Infastructure Reverse Engineer
    Location:
    Liverpool UK
    here is another one in c# inputsimulator.codeplex.com
     
  4. xenon2010

    xenon2010 Regular Member

    Joined:
    Apr 27, 2010
    Messages:
    231
    Likes Received:
    48
    Occupation:
    web and desktop apps programmer
    Location:
    prison
    Home Page:
    what do you mean by "simulate typing in my bot"?
    its not achievable with "httpwebrequests". because its not an actual webbrowser..
     
  5. vebxperts

    vebxperts Jr. VIP Jr. VIP Premium Member

    Joined:
    Nov 15, 2008
    Messages:
    1,657
    Likes Received:
    339
    Exactly, its not achievable in httpwebrequests because for this web browser control is required and you can do it by SendKey{"A/B/C/etc"} function in my opinion.