Jump to content

Msn bot won't work


Vicks
 Share

Recommended Posts

#include <Date.au3>
$Time =  _NowTime()
$Date =  _DateTimeFormat( _NowCalc() ,1)
Dim $window[99]
IniWrite("Friends list.ini" , "Friends" , "1" , "myfriend")
IniWrite("Friends list.ini" , "Friends" , "2" , "- SmarterChild -")
IniWrite("Friends list.ini" , "Friends" , "3" , "test")
IniWrite("Friends list.ini" , "Friends" , "4" , "type your friends name here")
IniWrite("Friends list.ini" , "Friends" , "5" , "type your friends name here")
IniWrite("Friends list.ini" , "Friends" , "6" , "type your friends name here")
IniWrite("Friends list.ini" , "Friends" , "7" , "type your friends name here")
IniWrite("Friends list.ini" , "Friends" , "8" , "type your friends name here")
IniWrite("Friends list.ini" , "Friends" , "9" , "type your friends name here")
IniWrite("Friends list.ini" , "Friends" , "10" , "type your friends name here")

$window[1] = IniRead("Friends list.ini", "Friends", "1", "NotFound")
$window[2] = IniRead("Friends list.ini", "Friends", "2", "NotFound")
$window[3] = IniRead("Friends list.ini", "Friends", "3", "NotFound")
$window[4] = IniRead("Friends list.ini", "Friends", "4", "NotFound")
$window[5] = IniRead("Friends list.ini", "Friends", "5", "NotFound")
$window[6] = IniRead("Friends list.ini", "Friends", "6", "NotFound")
$window[7] = IniRead("Friends list.ini", "Friends", "7", "NotFound")
$window[8] = IniRead("Friends list.ini", "Friends", "8", "NotFound")
$window[9] = IniRead("Friends list.ini", "Friends", "9", "NotFound")
$window[10] = IniRead("Friends list.ini", "Friends", "10", "NotFound")
If @error Then 
    MsgBox(4096, "", "Error occurred, probably no INI file.")
EndIf

While 1
If WinExists($window) Then
    WinActivate($window) 
Sleep(500)
_sendit()
;_exit()
EndIf
WEnd

    Func _sendit()
Send("Auto Bot: 010101010001 is busy please contact him in a little bit.... logging time and date." &  $Time  &   $Date)
Sleep(100)
Send("{ENTER}")
If WinExists($window) Then
    WinKill($window)
    EndIf
    EndFunc

;Func _exit()
;   If WinExists($window) Then
;   WinKill($window)
;   EndIf
;   EndFunc

i need find away to get peoples msn user names, and for some reason the code trys and reboots me, if you don't know what i am trying to do say your away from your computer it will type a message to that person let them know your away

[s]Autoit[/s]
Link to comment
Share on other sites

  • Moderators

Logic issue with $Time and $Date... you only put it in the Varible when the script starts, so it will always be the same... try putting it in the function for 1.

And your checking $window when you have $window as an array, your trying to check it as a string.

Try this:

#include <Date.au3>
Global $window = IniReadSection('Friends list.ini', 'Friends')
While 1
    For $iCC = 1 To $window[0][0]
        If WinExists($window[$iCC][1]) Then
            WinActivate($window[$iCC][1])
            Sleep(500)
            _sendit($window[$iCC][1])
            ;_exit()
        EndIf
    Next
    Sleep(100)
WEnd
Func _sendit($sWin)
    Local $Time = _NowTime()
    Local $Date = _DateTimeFormat(_NowCalc(), 1)
    Send("Auto Bot: 010101010001 is busy please contact him in a little bit.... logging time and date." & $Time & $Date)
    Sleep(100)
    Send("{ENTER}")
    If WinExists($sWin) Then
        WinKill($sWin)
    EndIf
    Return 1
EndFunc
Notice I'm passing a parameter (the window itself) as well.

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

Logic issue with $Time and $Date... you only put it in the Varible when the script starts, so it will always be the same... try putting it in the function for 1.

And your checking $window when you have $window as an array, your trying to check it as a string.

Try this:

#include <Date.au3>
Global $window = IniReadSection('Friends list.ini', 'Friends')
While 1
    For $iCC = 1 To $window[0][0]
        If WinExists($window[$iCC][1]) Then
            WinActivate($window[$iCC][1])
            Sleep(500)
            _sendit($window[$iCC][1])
            ;_exit()
        EndIf
    Next
    Sleep(100)
WEnd
Func _sendit($sWin)
    Local $Time = _NowTime()
    Local $Date = _DateTimeFormat(_NowCalc(), 1)
    Send("Auto Bot: 010101010001 is busy please contact him in a little bit.... logging time and date." & $Time & $Date)
    Sleep(100)
    Send("{ENTER}")
    If WinExists($sWin) Then
        WinKill($sWin)
    EndIf
    Return 1
EndFunc
Notice I'm passing a parameter (the window itself) as well.
nice one now if only there was away of the script to get your friends usernames or it can see if a conversation box is opened that would be even better
[s]Autoit[/s]
Link to comment
Share on other sites

  • Moderators

nice one now if only there was away of the script to get your friends usernames or it can see if a conversation box is opened that would be even better

That could easily be made into a spam bot then, I won't help on that venture.

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

That could easily be made into a spam bot then, I won't help on that venture.

i am not into spam bots but your right this code could be changed although autoit has mostly all decent people so i wouldn't worry to much, there is plenty of auto responders but i want my own, anyways i edited the code a bit now, you can make your own custom message and it logs time date and user, soon it will log what they said to you as well or you could just check your message history. but there is a slight problem it like to keep logging

#include <Date.au3>
Global $window = IniReadSection('Friends list.ini', 'Friends')
$YourMessage = InputBox("Type Your Message" , "write your message here" , "Auto Bot: John is busy please contact him in a little bit.... logging time and date." , "" , 500 , 30 , -1 ,-1)
While 1
    For $iCC = 1 To $window[0][0]
        If WinExists($window[$iCC][1]) Then
            WinActivate($window[$iCC][1])
            Sleep(500)
            _sendit($window[$iCC][1])
            ;_exit()
        EndIf
    Next
    Sleep(100)
WEnd
Func _sendit($sWin)
    Local $Time = _NowTime()
    Local $Date = _DateTimeFormat(_NowCalc(), 1)
    Send($YourMessage & $Time & $Date)
    Sleep(100)
    Send("{ENTER}")
    FileWrite("Log.txt" , "logged Note this has been logged a few seconds after someone message you" & $Time & $Date & $sWin)
   If WinExists($sWin) Then
        WinKill($sWin)
    EndIf
    Return 1
EndFunc
[s]Autoit[/s]
Link to comment
Share on other sites

  • Moderators

Might want to make the "$YourMessage" Global or pass it as a parameter. Then window probably still exists if it keeps logging, Change:

If WinExists($sWin) Then
        WinKill($sWin)
    EndIfoÝ÷ Ù:ºÚ"µÍÚ[HÚ[^ÝÊ ÌÍÜÕÚ[BÚ[ÛÜÙJ  ÌÍÜÕÚ[BÚ[Ú[
    ÌÍÜÕÚ[BÛY
L
BÑ[
and see if that helps.

Edited by SmOke_N

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

Might want to make the "$YourMessage" Global or pass it as a parameter. Then window probably still exists if it keeps logging, Change:
If WinExists($sWin) Then
        WinKill($sWin)
    EndIfoÝ÷ Ù:ºÚ"µÍÚ[HÚ[^ÝÊ ÌÍÜÕÚ[BÚ[ÛÜÙJ  ÌÍÜÕÚ[BÚ[Ú[
    ÌÍÜÕÚ[BÛY
L
BÑ[oÝ÷ ٩ݱç¢~ØZ¶¥¦Ïêº^¶§Èfz-²êÞ-¢­¶­{ZØ£ºËpj{m¢­Â­¶®±êìj'g¢Ûa{hì"Ú0µìmjëh×6
#cs ----------------------------------------------------------------------------

 AutoIt Version: 3.1.1.0
 Author:         myName

 Script Function:
    Template AutoIt script.

#ce ----------------------------------------------------------------------------

; Script Start - Add your code below here

#include <Date.au3>
$GetText = WinGetText($sWin)
If Not FileExists("Friends list.ini") Then
    IniWrite("Friends list.ini" , "Friends" , "1" , "Type your friends msn user name here")
    EndIf
Global $window = IniReadSection('Friends list.ini', 'Friends')
If @error Then 
    MsgBox(4096, "", "Error occurred, probably no INI file.")
    Exit
EndIf
$YourMessage = InputBox("Type Your Message" , "write your message here" , "Auto Bot: John is busy please contact him in a little bit.... logging time and date." , "" , 500 , 30 , -1 ,-1)
While 1
    For $iCC = 1 To $window[0][0]
        If WinExists($window[$iCC][1]) Then
            WinActivate($window[$iCC][1])
            Sleep(500)
            _sendit($window[$iCC][1])
            ;_exit()
        EndIf
    Next
    Sleep(100)
WEnd
Func _sendit($sWin)
    Local $Time = _NowTime()
    Local $Date = _DateTimeFormat(_NowCalc(), 1)
    Send($YourMessage & $Time & $Date)
    Sleep(100)
    Send("{ENTER}")
    FileWrite("Log.txt" , "logged a few seconds after someone message you" & $Time & $Date & $sWin & "the person who messaged you said" & $GetText)
 While WinExists($sWin)
        WinClose($sWin)
        WinKill($sWin)
        Sleep(10)
    WEnd
    Return 1
EndFunc
Edited by Vicks
[s]Autoit[/s]
Link to comment
Share on other sites

  • Moderators

I'm not sure, but doesn't MSN offer "Log" chatting itself? If it does, you could just get it from there couldn't you?

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

I'm not sure, but doesn't MSN offer "Log" chatting itself? If it does, you could just get it from there couldn't you?

yes it does but not everybody turns on msn history logging

Brad aka spyro made a "Perfect" one, but it only works for old msn and well in with the new out with the old so to speak thats how i am atleast

Edited by Vicks
[s]Autoit[/s]
Link to comment
Share on other sites

  • Moderators

yes it does but not everybody turns on msn history logging

Brad aka spyro made a "Perfect" one, but it only works for old msn and well in with the new out with the old so to speak thats how i am atleast

Yeah, I didn't know you were going to give this out, then my previous statement definately stands.

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

Yeah, I didn't know you were going to give this out, then my previous statement definately stands.

i didn't say i was releasing it i was only gonna give it to my firends they don't spam

and when i said everybody doesn't turn there msn history on i was pointing myself out since i don't use the history got me in troble one time :P

edited: and you know how easy it is making spam bots people don't need to look at this code just need mouseclick() to click on your contacts and hotkeys() and send() and thats why msn has the block function build in :nuke: and who would spam there friends unless they are really dumb? and msn isn't supported in games, so i think even if i did release it, it would be safe. i know were to find keyloggers on this forum and make them thats worst then spammers by far

i am not disagreeing with you Smoke because your cool but i don't want my script to down fall and be forgotton just becuase of spammers, the spammers could be blocked easyly in one click anyways

Edited by Vicks
[s]Autoit[/s]
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...