Go Back   Winamp Forums > Developer Center > NSIS Discussion

Reply
Thread Tools Search this Thread Display Modes
Old 31st August 2006, 12:13   #1
andis59
Junior Member
 
Join Date: Aug 2006
Posts: 4
Strange behaviour by StrCpy

Hello!

I have inherit a rather large installation script and I'm getting some error that I can't fix.

The error.

Quote:
StrCpy expects 2-4 parameters, got 5.
Usage: StrCpy $(user_var: output) str [maxlen] [startoffset]
The Code:

!define PRODUCER 'My Company Inc'
!define NAMEPROD 'My Very Nice Program'
!define MAJOR '4'
!define MINOR 1
!define RELEASE '2'
!define PRODUCT "${NAMEPROD}${MAJOR}.${MINOR}"
!define PRODNAME "${NAMEPROD} ${MAJOR}.${MINOR}.${RELEASE}"
!define LOGFILE "$WINDIR\${NAMEPROD}${MAJOR}${MINOR}${RELEASE}_${PRODUCER}_${DATE}.log "

StrCpy $0 ${LOGFILE} ; here I get the error!

I'm getting that the error is due to the fact that PRODUCER and NAMEPROD is containing spaces, but why? and how do I fix it?

Removing the spaces is not a valid option!

// Anders
andis59 is offline   Reply With Quote
Old 31st August 2006, 12:33   #2
niteflyer
Member
 
Join Date: Mar 2004
Posts: 73
You should
!define LOGFILE `"Logfile's path"`
Watch the quotes !
niteflyer is offline   Reply With Quote
Old 31st August 2006, 14:36   #3
galil
Member
 
Join Date: Jan 2003
Posts: 83
FFS...
code:
StrCpy $0 "${LOGFILE}"
galil is offline   Reply With Quote
Old 1st September 2006, 11:43   #4
andis59
Junior Member
 
Join Date: Aug 2006
Posts: 4
Yes of course!!!!

I must have been booted in stupid mode...

// Anders
andis59 is offline   Reply With Quote
Reply
Go Back   Winamp 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