Old 14th November 2005, 08:22   #1
Axonn
Guest
 
Posts: n/a
if ($0 == 1) { do something }

Hi again. One more question... I use ExecWait to execute a file once installed. Like this:

ExecWait '"$INSTDIR\zLoadIcon2.exe"' $0

So then the exit code of that Application will go in $0. But then if $0 is 1 I want to Abort the install and if it's 0 to continue... something like this...

if ($0 == 1) { do something }

I don't know if NSIS has support for such conditional checking and I checked the documentation and this forum but didn't find anything of use so far. So can it be done?
  Reply With Quote
Old 14th November 2005, 11:32   #2
glory_man
Senior Member
 
Join Date: Sep 2004
Location: Mogilev (Belarus)
Posts: 372
Use strcmp instruction. Or LogicLib.nsh and If statement.

EDIT. Or InCmp instruction instead strcmp.

Last edited by glory_man; 14th November 2005 at 12:46.
glory_man is offline   Reply With Quote
Old 14th November 2005, 14:24   #3
Axonn
Guest
 
Posts: n/a
Thanks

Thank you. Let me see if it works : D.
  Reply With Quote
Old 14th November 2005, 17:27   #4
Axonn
Guest
 
Posts: n/a
Nope

I can see no such instruction "lncmp" in my NSIS (2.11) documentation. However, the other solutions seem to be ok so thanks a lot ::- D.
  Reply With Quote
Old 14th November 2005, 17:33   #5
Joel
Debian user
(Forum King)
 
Joel's Avatar
 
Join Date: Jan 2003
Location: Arch land
Posts: 4,917
Re: Nope

Quote:
Originally posted by Axonn
I can see no such instruction "lncmp" in my NSIS (2.11) documentation. However, the other solutions seem to be ok so thanks a lot ::- D.
IntCmp


* PC: Intel Core 2 DUO E6550 @ 2.33 GHz with 2 GB RAM: Archlinux-i686 with MATE.
* Laptop: Intel Core 2 DUO T6600 @ 2.20 GHz with 4 GB RAM: Archlinux-x86-64 with MATE.
Joel is offline   Reply With Quote
Old 14th November 2005, 19:45   #6
Axonn
Guest
 
Posts: n/a
Hhehe

I should have known : D.
  Reply With Quote
Reply
Go Back   Winamp & Shoutcast Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump