ip addres script question
hi all
I'm trying to make a script based upon the script of Hendri Adriaens fouded here: http://nsis.sourceforge.net/wiki/IPTest
what im trying to do is after 4 times checking the Network IP-address the script must end but for some reason i cant get this to work, if not connected the script loops.
any help
Section
NoLoopBackIp:
; Code to use actual ExtensionDLL
; Current script provides an example
>;Pop $0
>---> again:
ip::get_ip
Pop$0
;test entry
;StrCpy $0 '192.168.0.100;127.0.0.1;152.168.0.101;169.254.0.1;'
Loop:
Push $0
Call GetNextIp
Call CheckIp
Pop$2 ; Type of current IP-address
Pop$1 ; Current IP-address
Pop$0 ; Remaining addresses
;StrCmp $2 '1' '' NoLoopBackIp
; MessageBox MB_OK "LoopBack IP-address: $1"
; Goto Continue
;
;StrCmp $2 '2' '' NoAPA
; MessageBox MB_OK "Automatic Private IP-address: $1"
; Goto Continue
;NoAPA:
StrCmp $2 '3' '' NoLanIp
MessageBox MB_OK "$2 Network IP-address: $1"
Goto Continue
--->noLanIp:
ClearErrors
---> IntOp $4 $4 + 1
---> StrCmp $R2 4 kill
MessageBox MB_OK|MB_ICONEXCLAMATION "$\r$\n$R2 Netwerk Internet verbindings fout :$\r$\n$\r$\nKan geen verbinding maken met server, bezig met opnieuw proberen... "
>---> Goto again
>---> kill:
MessageBox MB_OK|MB_ICONEXCLAMATION "$\r$\nR2 Kan geen Internet Vebinding maken, setup sluit nu af... "
quit
;MessageBox MB_OK|MB_ICONEXCLAMATION "$\r$\nKan geen Internet Vebinding maken, setup sluit nu af... "
; quit
;MessageBox MB_OK "Internet IP-address: $1"
Continue:
StrCmp $0 '' ExitLoop ExitLoop2
ExitLoop:
ExitLoop2:
>quit
SectionEnd
>