+ Reply to Thread
Results 1 to 10 of 10

Thread: AutoTyper(Spammer) In C#

  1. #1
    Kierien's Avatar
    Kierien is offline Learning Programmer
    Join Date
    Jan 2009
    Posts
    32
    Rep Power
    13

    AutoTyper(Spammer) In C#

    Hey,

    This tut is extremely simple, a good one for C# beginners =)

    First create a new C# project by going to

    Code:
    File>New>C#>Windows Forms Application
    Then add 1 timer, 3 textboxes, and 2 buttons.

    First were gonna give your timer a code, double click on your timer and add this code

    Code:
    SendKeys.Send(textBox1.text);
    SendKeys.Send("{ENTER}");
    SendKeys.Send(textBox2.text);
    SendKeys.Send("{ENTER}");
    SendKeys.Send(textBox3.text);
    SendKeys.Send("{ENTER}");
    The SendKeys Function basically types out the text you specify.

    Now rename one of your buttons to "Start", and give it the following code

    Code:
    timer1.Enabled = true;
    This enabled the timer, which in return, starts spamming your text.

    Then rename another one to "Stop", and give it the code below

    Code:
    timer1.Enabled = false;
    This disables your times, which stops the spamming.

    And ur done =D

    How simple was that?

    Hope you learned a thing or two from this.

    ~kierien
    Last edited by Kierien; 01-31-2009 at 09:02 PM.

  2. CODECALL Circuit advertisement
    Join Date
    Always
    Posts
    Many

     
  3. #2
    Jordan Guest

    Re: AutoTyper(Spammer) In C#

    Not bad, perhaps a bit more explanation though? Newbs are not going to know what a timer does or what the SendKeys class is. Perhaps you should give more detail on these two things. Also, don't you need a timer_tick function before your timer1 will do anything?

  4. #3
    Kierien's Avatar
    Kierien is offline Learning Programmer
    Join Date
    Jan 2009
    Posts
    32
    Rep Power
    13

    Re: AutoTyper(Spammer) In C#

    Quote Originally Posted by Jordan View Post
    Not bad, perhaps a bit more explanation though? Newbs are not going to know what a timer does or what the SendKeys class is. Perhaps you should give more detail on these two things. Also, don't you need a timer_tick function before your timer1 will do anything?
    Alright, will reedit to more detail, and no we dont need a timer_tick, because we already have our timer enabled and disabled via buttons.

    ~kierien

  5. #4
    Join Date
    Mar 2008
    Location
    The North Pole
    Posts
    13,174
    Blog Entries
    13
    Rep Power
    114

    Re: AutoTyper(Spammer) In C#

    You have misunderstood. Timer_Tick is the subroutine that runs whenever the timer ticks.

    All of this code:

    Code:
    SendKeys.Send(textBox1.text);
    SendKeys.Send("{ENTER}");
    SendKeys.Send(textBox2.text);
    SendKeys.Send("{ENTER}");
    SendKeys.Send(textBox3.text);
    SendKeys.Send("{ENTER}");
    ..is put within the timer_tick subroutine.

    Quote Originally Posted by Jordan View Post
    Good members, like yourself, stick around and post for ages to come!
    Mr. Xav | Blog | Forums

  6. #5
    wajouba is offline Newbie
    Join Date
    Jul 2009
    Posts
    6
    Rep Power
    0

    Re: AutoTyper(Spammer) In C#

    ok, I'm very new, so should I attempt this or not, cause it looks like its incomplete or lacking info...?!


  7. #6
    wajouba is offline Newbie
    Join Date
    Jul 2009
    Posts
    6
    Rep Power
    0

    Re: AutoTyper(Spammer) In C#

    I tried this, and got some errors at the end of each of the SendKeys.Send(textBox1.text);

    the error is:
    dosn't contain definition for text and no extension method text.

    Did I need a reference that I didn't use?! :S
    I don't get it sorry I'm new :$

  8. #7
    Kierien's Avatar
    Kierien is offline Learning Programmer
    Join Date
    Jan 2009
    Posts
    32
    Rep Power
    13

    Re: AutoTyper(Spammer) In C#

    It's .Text, not .text

  9. #8
    Join Date
    Mar 2008
    Posts
    7,145
    Rep Power
    86

    Re: AutoTyper(Spammer) In C#

    I think the IDE will correct that for you.

    What does this do?

    Code:
    SendKeys.Send(textBox1.text);
    Like Jordan said, newbs won't understand what this is doing.

    Code:
    Now rename one of your buttons to "Start"
    Why? I don't see anywhere in your code, you referencing the button that you want me to call "Start". So why should I?

    Alright, will reedit to more detail, and no we dont need a timer_tick, because we already have our timer enabled and disabled via buttons.
    Yes, you do need a timer_tick method. When you double click on a timer, one is created for you.

  10. #9
    wajouba is offline Newbie
    Join Date
    Jul 2009
    Posts
    6
    Rep Power
    0

    Re: AutoTyper(Spammer) In C#

    yes its true im trying to figure out what its doing, but I guess tomorow mourning would be better... plus you are right .Text was the problem, I did it and I got stuck in the autospamer when I tried it...

  11. #10
    Kierien's Avatar
    Kierien is offline Learning Programmer
    Join Date
    Jan 2009
    Posts
    32
    Rep Power
    13

    Re: AutoTyper(Spammer) In C#

    Quote Originally Posted by chili5 View Post
    I think the IDE will correct that for you.

    What does this do?

    Code:
    SendKeys.Send(textBox1.text);
    Like Jordan said, newbs won't understand what this is doing.

    Code:
    Now rename one of your buttons to "Start"
    Why? I don't see anywhere in your code, you referencing the button that you want me to call "Start". So why should I?



    Yes, you do need a timer_tick method. When you double click on a timer, one is created for you.
    First of all, i wanted to rename the button to "Start" so that things will look neater. Secondly, yes i know when i double click on a timer a timer_tick is created for me. But i was referring to Jordan's post on whether a timer_tick was needed before the timer would function. And yeah we would need one, but it's already created anyway.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Beginner Chat spammer
    By Demon in forum Visual Basic Tutorials
    Replies: 15
    Last Post: 07-30-2011, 05:09 PM
  2. Spammer alert
    By Roger in forum Announcements
    Replies: 44
    Last Post: 10-09-2010, 05:49 AM
  3. [C#] Basic Autotyper
    By Charny in forum Video Tutorials
    Replies: 0
    Last Post: 06-30-2010, 01:06 AM
  4. Charny Autotyper [v1.0]
    By Charny in forum Member Software/Projects
    Replies: 0
    Last Post: 03-26-2010, 02:44 PM
  5. Spammer/Typer/Whatever...
    By Rascagua in forum Visual Basic Programming
    Replies: 3
    Last Post: 05-10-2007, 05:14 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts