This website uses cookies. By clicking Accept, you consent to the use of cookies. Click Here to learn more about how we use cookies.
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
- Revenera Community
- :
- InstallShield
- :
- InstallShield Forum
- :
- Predefined Folders w/ Installscript proj??
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Feb 26, 2008
01:42 PM
Predefined Folders w/ Installscript proj??
I have two Installscript projects. I need to add a file to the user's "My Documents" folder. When I right-click "Destination Computer" to select "Show Predefined Folders" it is grayed out.
Are "Predefined Folders" not available for Installscript projects? If they are available, what would cause the graying out? If not available in Installscript projects, what's the best way to get something into "My Documents"??
-- Thanks
Are "Predefined Folders" not available for Installscript projects? If they are available, what would cause the graying out? If not available in Installscript projects, what's the best way to get something into "My Documents"??
-- Thanks
(3) Replies
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Feb 27, 2008
01:41 PM
Chris,
If the predefined variables are not available you can get to "My Documents" by querying the environment variable USERPROFILE and append "My Documents" to the returned path.
This will work for English systems only. You will have to get "My Documents" translated for globalized installations.
Cheers,
ME
If the predefined variables are not available you can get to "My Documents" by querying the environment variable USERPROFILE and append "My Documents" to the returned path.
if( GetEnvVar( "USERPROFILE", svProfilePath ) < 0 ) then
Sprintf( svMsg, @MSG_FIND_ENVVAR_FAIL, "USERPROFILE" );
MessageBox( svMsg, SEVERE );
abort;
else
svDocPath = svProfilePath ^ "My Documents";
endif;
This will work for English systems only. You will have to get "My Documents" translated for globalized installations.
Cheers,
ME
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Feb 27, 2008
04:49 PM
ME,
I think it's possible for My Docs to be somewhere besides under UserProfile (though I'm not sure). But I also have to deal with different languages. I guess I need to try to call into the ShFolder dll.
I was hoping someone might explain why InstallShield doesn't show "Predefined Folders" for Installscript projects.
Thanks - Chris
I think it's possible for My Docs to be somewhere besides under UserProfile (though I'm not sure). But I also have to deal with different languages. I guess I need to try to call into the ShFolder dll.
I was hoping someone might explain why InstallShield doesn't show "Predefined Folders" for Installscript projects.
Thanks - Chris
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Feb 27, 2008
05:30 PM
Chris,
You are correct, My Documents can be anywhere. I don't know why predefined shell folders are not shown in InstallScript projects however you can find them in the registry easy enough without any issues with OS language. They are located at HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders.
The variable Personal contains the path to My Documents.
Hope someone from Macrovision can answer your question.
Cheers,
ME
You are correct, My Documents can be anywhere. I don't know why predefined shell folders are not shown in InstallScript projects however you can find them in the registry easy enough without any issues with OS language. They are located at HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders.
The variable Personal contains the path to My Documents.
Hope someone from Macrovision can answer your question.
Cheers,
ME