Jump to content


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.
Photo

Creating a folder and setting to to be compressed on NTFS


1 reply to this topic

deramor

deramor
  • Full Members
  • 187 posts

Posted 29 October 2014 - 00:17

Hello-

 

I was asked recently is Installshield could create a folder and set it to be a compressed folder on a NTFS files system.

I did not immediately see any options in the UI to do this, nothing in the help file, and some googling all came up empty.

 

If there is no setting in Installshield to do this, would anyone have a command-line exe that can do this that comes with Windows?  We want to create a folder for log files and they can get very large very quickly but since the logs are XML, they are very compressible.

 

Any help is appreciated.

 

Rob



Glytzhkof

Glytzhkof
  • Moderators
  • 1,447 posts

Posted 29 October 2014 - 04:00

I am not sure if there is an option for this in Installshield's GUI, I don't have the tool available at this time. You can however get the task done via a simple VBScript and WMI:

strComputer = "."
Set objWMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")

Set folders = objWMIService.ExecQuery _
("Select * from Win32_Directory where name = 'c:\\folder'")

For Each folder in folders
   res = folder.Compress
Next

Regards
-Stein Åsmul