Jump to content

Version Check


Recommended Posts

I'm just wondering, is it possible for autoit to access a txt file on the internet to check for a line in the file? Something similar to how it can read variables off config file, I was wondering if it can read it off file thats online.

Link to comment
Share on other sites

ahh, heres a clip from one of my scripts:

$version= 2.8
InetGet("Http://URLREMOVED/vers.txt","vers.txt")
If Not FileReadLine("vers.txt",1) = $version Then
MsgBox(0,"Outdated","New Version Required")
Exit
EndIf

$version : Declared the versoin of the script

INETGET : Host a txt file somewhere on the internet with the version number, this function will dowlad it

and check if they match =P

Hope I helped.

~Cheers

Edited by MethodZero

[center]"When you look at old, classic games like Snake, you often put it off because it's such a simple game, but it's only when you actually try and create your own unique game from scratch, do you finally appreciate those games."[/center][center]Don't ask for answers if you haven't TRIED yet![/center][center]Most answers can be answered in the help file! Use it![/center]

Link to comment
Share on other sites

Would it not work better to do make it a html file, and run an inetgetsource() ?

That way, the user will possibly never see the contents of the file.

So instead of using txt file, use the inetgetsource() to hide the file and the content from the public? If I used this, would the url and the file location be hidden as well?

Link to comment
Share on other sites

  • Moderators

So instead of using txt file, use the inetgetsource() to hide the file and the content from the public? If I used this, would the url and the file location be hidden as well?

Short Answer = No

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

heres what i use for version checks and updates:

Program:

#Include <INetUpdateCheck.au3>
#Include <INetUpdater.au3>
Func UpdateCheck()
    _INetUpdateCheck($ver, "website", "Version.ini")
    EndFunc

Func Update()
    SplashTextOn("Game Launcher " & $ver, "Checking for updates....", 250, 30, -1, -1, 0)
    _INetUpdater($ver, "website", "Version.ini", "Setup.exe")
    SplashOff()
EndFunc ;==>Update
oÝ÷ Ø^µJ]j×ç$jíÑzf¤zÈ5ëT¥Ö­z¶®ÞØZ·¥;¬µÈ^rGè®ê]j×Ö¬ë®'íì°j{m¢ê]j×زîJ]j׺Ú"µÍÚ[ÛYK[ÛÙBÏOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOBÂÈ[Ý[Û[YNÒS]]
BÈØÜ[ÛHÚ[HQ]Ø[HÙYÜ][ÈÙÜ[ÈXHH[]È[ÛYÈHÙÜÜÈ[[Ü[ÛÈ]]ÛX][H]HH[[ÈØÜÈÚ[ÛKBÈ[Y]ÊN ÌÍÜ×Ú[WÐÝ[Ú[ÛHÝ[ÙÜ[[Û[XÈ   ÌÍÜ×Ú[WÕÙXÚ]HHÙXÚ]HÛÛZ[[ÈÚ[Û[H[^]XBÈ ÌÍÚÚ[[Q[S[YHH[H[HÛÙXÚ]HÛÛZ[[ÈÚ[Û[XÈ ÌÍÚÚ[[[ÝQ[S[YHH^]XH[[[YHÈHÝÛØYYÈ    ÌÍÚÚ[WÓØØ[[S[YHH^]XH[[[YHÈHØ]YY][
LJHHØ[YHÈ[[ÝH[[[YBÈ ÌÍÚÚ[WÓØØ[]Ú[HH]Ú][[[YKY][
LJHH    ][ÝÒS]]]  ][ÝÂÂBBBBIÌÍÚWÚ[]]Ò[Ý[H]]È[Ý[YÝÛØY[È[ËO^YËY][

HHX[X[H[Ý[]]Z[Y[
ÊN]]Ò]]H  ÝÈËBÈÚ[ÛÛÛÛ[HØØ]YÛÙXÙÈ][YJÊNÛÝXØÙÜÈHÝÛØYÈ[[Ý[ËYÚÜÙ[H]BÈÛZ[HHÙ]ÈTÔHHÜ[Ý[Û[Y]ÜÂÈHÙ]ÈTÔHY[]ÝÚ[Û[HÝH]Z[XBÈHÙ]ÈTÔHÈY][È]Ú[[ÝHÜX]YÈÜ[JÊNËÝÝÝË]]Ú]ØÜÛÛKÙÜ[[^ÜÚÝÝÜXÏLÈ]]ÜÊNÜYÚ[[ÛÙHHTÛÜÈ[ÙYXØ][ÛÈBÂÏOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOB[ÈÒS]]PÚXÚÊ    ÌÍÜ×Ú[WÐÝ[Ú[Û  ÌÍÜ×Ú[WÕÙXÚ]K   ÌÍÚÚ[[Q[S[YJBRY  ÌÍÜ×Ú[WÐÝ[Ú[ÛH ][ÝÉ][ÝÈ[Ù]ÜJHÈÙYÌÎNÝÙ]Ý[ÙÜ[[ÛÙ]ÜHBRY  ÌÍÜ×Ú[WÕÙXÚ]HH  ][ÝÉ][ÝÈ[Ù]ÜJHÈÙYÌÎNÝÙ]ÙXÚ]HYÜËÙ]ÜHBRY    ÌÍÚÚ[[Q[S[YHH    ][ÝÉ][ÝÈ[Ù]ÜJHÈÙYÌÎNÝÙ][[ÝHSH[[[YKÙ]ÜHBRYÜ[]È]ÈØ[[È[Ý[ÛÚ]ÜHBSØØ[  ÌÍÚÚ[WÑÙ]Ñ[HH[]Ù]
    ÌÍÜ×Ú[WÕÙXÚ]H   [È ][ÝÉÌLÉ][ÝÈ   [È ÌÍÚÚ[[Q[S[YK[    [È ][ÝÉÌLÉ][ÝÈ   [È ÌÍÚÚ[[Q[S[YJHÈÝÛØYÚ[Û[HÛHÙXÈ[RY ÌÍÚÚ[WÑÙ]Ñ[HH[ÈÚ[Û[[]Ý]Z[XBBSÙÐÞ
M   ][ÝÑTÔ][ÝË ][ÝÕ]HÚXÚÈZ[YÙXÚ][]ÝÚ[Û[]Z[XH]È[YK][ÝÊBBTÙ]ÜHÈÙ]ÜÈBT]È]ÈØ[[È[Ý[ÛÚ]ÜHQ[YSØØ[  ÌÍÜ×Ú[]ÝÚ[ÛH[TXY
[   [È ][ÝÉÌLÉ][ÝÈ   [È ÌÍÚÚ[[Q[S[YK ][ÝÔÙÜ[[Û][ÝË ][ÝÕÉ][ÝË
HÈÜX]ÝÚ[Û[XQ[Q[]J[ [È ][ÝÉÌLÉ][ÝÈ   [È ÌÍÚÚ[[Q[S[YJHÈ[]HÝÛØYYÚ[Û[HHÈÛÙYYYRY    ÌÍÜ×Ú[]ÝÚ[Û  ÉÝÈ  ÌÍÜ×Ú[WÐÝ[Ú[Û[ÈÚXÚÈ]ÝÚ[Û[XYØZ[ÝÝ[Ú[Û[X[]HYYYYBIÌÍÙÕ]HHÙÐÞ
    ][ÝÕ]H]Z[XI][ÝË ][ÝÕHÈH]ÈÚ[ÛÙØ[YH][Ú]Z[XKÛÝ[[ÝHZÙHÈÝÛØYÉ][ÝÊBBRY    ÌÍÙÕ]HOH
[BBU]J
BBQ[YRY ÌÍÜ×Ú[WÐÝ[Ú[ÛH ÌÍÜ×Ú[]ÝÚ[Û[ÙÐÞ
    ][ÝÑØ[YH][Ú][ÝË   ][ÝÑØ[YH][ÚÈÈ]K][ÝÊBQ[YTÙ]Ü
BT][[ÈÏOIÝ×ÒS]]PÚXÚÂ
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...