Archive: Custom EstimatedSize


Custom EstimatedSize
I tried several method to apply EstimatedSize by Installer, finally I put 'InstallLocation' value to Uninstall Registry Key ie: 'HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\(My Product)' to show size in Add-Remove Programs.

Now my problem is I install binary in %ProgramFiles% which is in 'InstallLocation' but I also install some data files under %UserProfile%\Application Data\ which is not pointed by 'InstallLocation' so only the size of %ProgramFiles%\My app is showing in Add-Remove.

Any ways to merge this two ?. I tried with EstimatedSize with a custom value but that never worked.


HKLM is shared by all users, %UserProfile% is user specific, there is no way for the control panel applet to calculate the combined size of all users with some data in their profile.


Sorry my Data path is All User. So is there is solution now ?..

C:\Documents and Settings\All Users\Application Data\My App


EstimatedSize is the only option on Win7: http://blogs.msdn.com/b/cjacks/archi...windows-7.aspx

For other systems you can set EstimatedSize but since it will probably not work ( http://blogs.msdn.com/b/oldnewthing/...93.aspx#641239 ) you can force it by hacking SlowInfoCache (There have been threads about this on the forum IIRC)

Another ugly ugly hacky hacky solution is to create a junction from inside your program files folder to your appdata folder so InstallLocation will look at both (NTFS only and junctions seem to confuse users etc)