_Kurt Posted March 19, 2007 Posted March 19, 2007 (edited) Hello,After realizing how annoying it was to receive a new email each New Reply in a Topic or New Personal Message, I decided to create a script that will check for that & notify me. This is real handy since sometimes I want to work on scripts and chat on the forum at the same time. I used an MSN-like GUI for the notification, if you click on it, it will navigate you to the latest reply, if you right-click on it, it will close. It seems to work fine, I've tested it out for a while and it's lookin' pretty good. You can keep updated on as many topics as you want so you can work on new projects & post in the forums! This script requires you to already be logged in, if you are receiving errors that you aren't logged in, simply re-log in and try again (this rarely happens). I've also included a Recent Notifications tray menu item incase you were away for a couple of minutes, this will keep you updated on events that have occured i.e. New Notifications, Errors, etc. ( handy when you need a bathroom break ).This script uses one file located at: @TempDir & "\ForumNotification.dat". This file is used to keep track of your settings. Just thought I'd let you guys know, I hate when scripts write files that I am unaware of. To delete this file, click the "Set to Default" button.How exactly does this work? The script records the latest reply on the topic link, and after every X seconds/minutes, it will grab the latest reply and compare it to the original reply. The script only uses _InetGetSource for the internet functions.Please post ANY problems that you experience.I'd also like to hear some improvements & feedback KurtFor those who may receive Msgbox's saying that they are not logged in, try re-logging into the forums and make sure you are logged into IE first.Update 3: [April 2nd]Added Auto-Login & Some Minor fixesUpdate 2: [March 26th]Fixed "Invalid Topic" bug from topics with no repliesUpdate 1: [March 19th]Added option to save your settings.Go ahead and test it! Run the script, post here, and watch the notification window pop up! Edited April 2, 2007 by _Kurt Awaiting Diablo III..
therks Posted March 19, 2007 Posted March 19, 2007 I get an invalid screen resolution error. Not all of us have the standard 4:3 screen ratio you know. (Widescreen laptop, my screen ratio is 8:5 and my standard resolution is 1280x800). My AutoIt Stuff | My Github
_Kurt Posted March 19, 2007 Author Posted March 19, 2007 Woops, my bad, updated attachment. Sorry, Kurt Awaiting Diablo III..
AutoItKing Posted March 19, 2007 Posted March 19, 2007 Very nice script!! I think I will be using this quite often. Thanks you very much! http://www.autoitking.co.nr Site is DOWN | My deviantART | No Topic Topic - Don't do it!-------------------- UDF's/Scripts:AutoIt: [BenEditor 3.6] [_ShutDown()]PHP: [CommentScript]Web Based AutoIt: [MemStats] [HTML to AU3] [User LogIn and SignUp script]
Moderators SmOke_N Posted March 19, 2007 Moderators Posted March 19, 2007 This is weird... I was going to do something like this last week but couldn't find the time. Nice. 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.
jpam Posted March 19, 2007 Posted March 19, 2007 Handy tool ! could you make a save function for the url's with autoload on startup ? couse every time i restart the comp i have to reinsert the url's that would be a nice future nice done ! jpam
jvanegmond Posted March 19, 2007 Posted March 19, 2007 It tells me "I'm not logged in." which confused me at first, but then I realized that this uses IE, and I've never used IE on this computer. So, I'd love it if you could make this ask you for your login/password. github.com/jvanegmond
_Kurt Posted March 19, 2007 Author Posted March 19, 2007 (edited) @jpam - Your suggestion has been added, see first post.EDIT: Problem Fixed@Rest - Thanks Kurt Edited April 2, 2007 by _Kurt Awaiting Diablo III..
jvanegmond Posted March 20, 2007 Posted March 20, 2007 I have just tried re logging in Firefox, and login in in IE. No success at all. Still tells me I am not logged in.. github.com/jvanegmond
_Kurt Posted March 20, 2007 Author Posted March 20, 2007 (edited) I have just tried re logging in Firefox, and login in in IE. No success at all. Still tells me I am not logged in..Hmm, try running this small script, don't change any lines. If you get an AU3Check error or a blank msgbox, this means that this won't be able to work. However, if you get a msgbox containing "X New Messages", I know how to fix your problem so we'd be in luck .EDIT: Problem solvedHope it works,Kurt Edited April 2, 2007 by _Kurt Awaiting Diablo III..
jvanegmond Posted March 20, 2007 Posted March 20, 2007 (edited) Thanks Kurt. I appreciate it. C:\Documents and Settings\Administrator\Bureaublad\Nieuw - AutoIt v3 Script.au3 (10) : ==> Subscript used with non-Array variable.: MsgBox(0,"",$CheckPM[0]) MsgBox(0,"",$CheckPM^ ERROREdit1:By the way, I manually checked the source of the page and it was there...· <a href="http://www.autoitscript.com/forum/index.php?act=Msg&CODE=01">-1 New Messages</a>Edit2: This works:#Include <Inet.au3> #Include <String.au3> $link = "http://www.autoitscript.com/forum/index.php?showtopic=42878" $source2 = _INetGetSource($link) If @error = 1 Then MsgBox(0,"","ERROR: Failed to retrieve source code from: " & $link) Else $a = StringRegExp($source2,"[0-9]+.New Messages",3) If Not @error Then MsgBox(0, "", $a[0]) EndIf EndIf Edited March 20, 2007 by Manadar github.com/jvanegmond
jvanegmond Posted March 20, 2007 Posted March 20, 2007 Or with the negative posts bug: #Include <Inet.au3> #Include <String.au3> $link = "http://www.autoitscript.com/forum/index.php?showtopic=42878" $source2 = _INetGetSource($link) If @error = 1 Then MsgBox(0,"","ERROR: Failed to retrieve source code from: " & $link) Else $a = StringRegExp($source2,"-?[0-9]+.New Messages",3) If Not @error Then MsgBox(0, "", $a[0]) EndIf EndIf github.com/jvanegmond
_Kurt Posted March 20, 2007 Author Posted March 20, 2007 (edited) EDIT: Problem SolvedKurt Edited March 20, 2007 by _Kurt Awaiting Diablo III..
jvanegmond Posted March 20, 2007 Posted March 20, 2007 (edited) You do that.. The code you gave me didn't work at all. ^^Edit: Now we just need to fix the initial bug.. Edited March 20, 2007 by Manadar github.com/jvanegmond
_Kurt Posted March 20, 2007 Author Posted March 20, 2007 (edited) Problem FixedKurt Edited April 2, 2007 by _Kurt Awaiting Diablo III..
jvanegmond Posted March 20, 2007 Posted March 20, 2007 (edited) That actually gives me an error... I've confirmed that I'm actually not logged in.#include <INet.au3> $login = _INetGetSource("http://www.autoitscript.com/forum/") If @error = 1 Then MsgBox(0,"","Error getting source: " & @error) Else MsgBox(0, "", StringInStr($login,"Welcome Guest")) EndIfGives a message box with a number 51xx. This confirms that I am a Guest. _INetGetSource just sucks...Edit: Upps!! IE had knocked me offline.. for Microsoft.I got it working, and I have no clue what I changed.. :| Edited March 20, 2007 by Manadar github.com/jvanegmond
_Kurt Posted March 20, 2007 Author Posted March 20, 2007 (edited) Problem FixedKurtEDIT: Yeepey! Had me scared for a second Edited April 2, 2007 by _Kurt Awaiting Diablo III..
_Kurt Posted March 20, 2007 Author Posted March 20, 2007 Is the script working for you now? or are you still experiencing similar problems? Kurt Awaiting Diablo III..
jvanegmond Posted March 21, 2007 Posted March 21, 2007 It's actually working now.. You have to be logged into IE first. github.com/jvanegmond
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now