Winamp & Shoutcast Forums

Winamp & Shoutcast Forums (http://forums.winamp.com/index.php)
-   NSIS Discussion (http://forums.winamp.com/forumdisplay.php?f=65)
-   -   SearchPath (http://forums.winamp.com/showthread.php?t=173646)

Lumberman 17th March 2004 02:37

SearchPath
 
in the following script, can't get "SearchPath" to read. $INSTDIR keeps coming up empty (defaults to C:). i'm working with 5 different OS's & 4 different versions of MS Office. ".xls" files are in different locations. need script to search for the path of each file and set it as the "SetOutPath"....any suggestions?

Name "${PRODUCT_NAME} ${PRODUCT_VERSION}"
OutFile "Setup.exe"
InstallDir $INSTDIR
ShowInstDetails Nevershow
SilentInstall silent

Section "MainSection" SEC01
SetOutPath $INSTDIR
SearchPath $INSTDIR UNTR.xls
SetOverwrite on
File "UNTR.xls"
SearchPath $INSTDIR Treated.xls
SetOverwrite on
File "Treated.xls"
SearchPath $INSTDIR HTOnly.xls
SetOverwrite on
File "HTOnly.xls"
SetOutPath $INSTDIR
SearchPath $INSTDIR WPM.xls
SetOverwrite on
File "WPM.xls"
SetOutPath $INSTDIR
SearchPath $INSTDIR Personal.xls
SetOverwrite on
File "..\Program Files\Microsoft Office\OFFICE11\XLSTART\Personal.xls"
SetAutoClose true
SectionEnd

Joost Verburg 17th March 2004 08:04

SearchPath does not search for a file. See the NSIS Archive for file search functions.

Lumberman 18th March 2004 00:49

thanks for the reply. doesn't SearchPath return the path of the file and assign it to the user variable "$INSTDIR"? looked through the archives for file search functions. very confusing....gonna keep looking.

Joost Verburg 18th March 2004 13:26

It does not search the whole hard drive. Please see http://nsis.sf.net/archive.


All times are GMT. The time now is 04:26.

Copyright © 1999 - 2010 Nullsoft. All Rights Reserved.