apoc333
27th October 2005 22:20 UTC
Two rename commands sequence
Hi,
I've got a little problem with the rename commands. In the following example the first command will work alway, but the second one will never work. Any suggestions what's the problem?
Rename "$INSTDIR\..\op-buch" "$INSTDIR\..\op-buch-backup-${PRODUCT_VERSION}"
Rename "$INSTDIR\..\op-buch-${PRODUCT_VERSION}" "$INSTDIR\..\op-buch"
Kind Regards,
Christoph
kichik
28th October 2005 00:05 UTC
Maybe you meant for it to have "-backup" as well?
Rename "$INSTDIR\..\op-buch-backup-${PRODUCT_VERSION}" "$INSTDIR\..\op-buch"
Or maybe "$INSTDIR\..\op-buch" already exists when you try to rename.
Try using a MessageBox to show the values of what you're trying to move so you can make sure everything is correct.
apoc333
29th October 2005 12:48 UTC
Okay, after playing arround a little, I found a working solution:
SetOutPath "$INSTDIR\..\"
Rename "OP-Buch" "OP-Buch-Backup-${PRODUCT_VERSION}"
Rename "OP-Buch-${PRODUCT_VERSION}" "OP-Buch"
Thanks anyway =)