Old 30th November 2007, 07:52   #1
mergisius
Junior Member
 
Join Date: Aug 2007
Location: Lithuania
Posts: 17
How to use ${un.GetParent} ?

I need to remove parent directory of installation directory if it's empty. After searching the forum i foundthis code.

${un.GetParent} $INSTDIR $R0
RMdir $R0

I've found out, that I need to include FilfeFunc.nsh.

But the error message didn't changed:
"Invalid command: ${un.GetParent}
Error in script "MC_Client_Install_client.template" on line 183 -- aborting crea
tion process"

How to call it in the correct form?
mergisius is offline   Reply With Quote
Old 30th November 2007, 08:34   #2
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
You also need to declare you're going to use GetParent by insert the un.GetParent macro after including FileFunc.nsh.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 30th November 2007, 12:17   #3
mergisius
Junior Member
 
Join Date: Aug 2007
Location: Lithuania
Posts: 17
thank you, kichik
mergisius is offline   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