need to copy 2 files in to music folder for each user
Hi For the itunes application i need to copy to 2 files in to user profile on our win 7. i tried to copy them using predefined folder in an msi [UserPRofile]\Music\..
whne installing the msi the msi is creating a folder music on C drive which its not suppose to do.. Then i tried to copy those files and vbs file in to c:\programfiles(x86)\itunes (basically the vbs file copies the two files in to %userprofile%\Music) and tried to run a vb script using activesetup...by creating a stubpath as wscript.exe "C:\Progam files (x86)\iTunes\name.vbs". But the active setup is also not working..as the active setup can't copy those two files in to %userprofile%\Music folder... If i run the vb script manually it works. Then i realized i'm doing some thing wrong...
I read many blogs on this But couldn't get this done. if any one can help me how to copy the those two files in to %userProfile% \Music folder..It would be really great help....Can u pls elobrate in detal if u don't mind so i may not miss any piece... Really appreciate all ur help and advices...
But the music folder is getting generated a
It maybe the case that your active setup is not working at all. Try installing it on a fresh machine.
To make sure, you can write a MsgBox inside your vbs to see if the vbs runs.
The process you have written is fine and should work.
Another thing which you can do is to write this vbs in your MSI and it will work when self heal happens when the advertised shortcut is launched. I have used this method in some of my packages and it has worked.
Here in this post you can get a VBScript which I wrote for almost the same purpose:
You can check your script against it or use this by changing paths.
Then I added this script in the package to run in Deffered execution system context, just before install finalize. condition was set as NOT REMOVE~="ALL"
Create a dummy key somewhere in HKCU in the same feature as the Advertised shortcut and make it a key path. It is easy to see this in Installshield through Setup Design. This will trigger the self heal and during self heal the script will run for the user and will copy the file.
Hope it helps.
Please follow as Piyush said.
Also don't forget to include the "version" in your active setup and a separate VBS be included in the MSI which increases the version on uninstallation.
This guarantees a fail proof active setup and will let you know if the VBS has run properly by refering the version.
N.B. For versioning of active setup please refer this site:
When you put the files in the MSI directly, in the UserProfile folder, did you give the component that contained these files a keypath that's a HKCU registry key, and did you make sure regular users have access to the original install location of the package?
And of course, did you have an advertised shortcut of another entry point to trigger MSI self-healing?