With InstallShield Express X
1. Organize your setup > General Information > I have set INSTALLDIR to [ProgramFilesFolder]Microsoft Office\Templates
2. Then in custom action
Custom Action During Installation > After Customer Information > GetTemplateFolderLoction
3. My custom action returns value something like this C:\Document and Settings\UserName\Application Data\Microsoft\Templates.
4. The dialog box during installation shows correct path as in step 3 above. But installer actually installed all files in [ProgramFilesFolder]Microsoft Office\Templates as shown in step 1, why?
This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.

InstallDir issue
Started by
kajal_shah16
, Sep 09 2004 04:16
3 replies to this topic
Posted 09 September 2004 - 20:42
Does your custom action set INSTALLDIR or InstallDir? It has to be a "set a directory" type of custom action, not a "set a property" action if it is called after CostFinalize. (CostFinalize is executed before the dialogs are displayed)
Stefan Krüger
InstallSite.org twitter facebook
Posted 10 September 2004 - 21:13
Here is my code of custom action
__declspec(dllexport)
char WINAPI TemplatesExt(HWND hWnd, LPSTR pszSrc, LPSTR pszSupport,
LPSTR pszInstall, LPSTR pszReserve)
{
char szTmp[256];
char szMsgBoxMessage[2*_MAX_PATH];
if(LoadTemplatesFolder(szTmp, sizeof(szTmp)))
{
strcpy(pszInstall, szTmp);
}
else
{
; // Do nothing - We will return with value 1 and InstallShield will continue
// install into default folder set in Installer script
}
return 1; // InstallShield continues only if it gets return = 1 otherwise it quits
}
I am calling it "after customer Information dialog" I do not see any other option to set in InstallShield Express X
__declspec(dllexport)
char WINAPI TemplatesExt(HWND hWnd, LPSTR pszSrc, LPSTR pszSupport,
LPSTR pszInstall, LPSTR pszReserve)
{
char szTmp[256];
char szMsgBoxMessage[2*_MAX_PATH];
if(LoadTemplatesFolder(szTmp, sizeof(szTmp)))
{
strcpy(pszInstall, szTmp);
}
else
{
; // Do nothing - We will return with value 1 and InstallShield will continue
// install into default folder set in Installer script
}
return 1; // InstallShield continues only if it gets return = 1 otherwise it quits
}
I am calling it "after customer Information dialog" I do not see any other option to set in InstallShield Express X
Posted 11 September 2004 - 10:49
I don't have X Express installed here, but isn't there an option to run that custom action at the very beginning, before any dialogs?
Stefan Krüger
InstallSite.org twitter facebook