The following script demonstrates how to set the size of the SMS Advanced Client cache, in megabytes (MB), using the Advanced Client Automation object method UIResourceMgr.GetCacheInfo.

For additional information about the Software Distribution Agent cache, see the SMS 2003 SDK.

Example

On Error Resume Next

Dim oUIResManager 
Dim oCache 
Dim CacheSize

CacheSize=260

Set oUIResManager = createobject("UIResource.UIResourceMgr")

If oUIResManager Is Nothing Then
	wscript.echo "Could not create Resource Manager - quitting"
	wscript.quit
End If

Set oCache=oUIResManager.GetCacheInfo()

If oCache Is Nothing Then
	Set oUIResManager=Nothing
	wscript.echo "Could not get cache info - quitting"
	wscript.quit
End If

oCache.TotalSize=CacheSize

Compiling the Code

  • Requires an SMS 2003 Advanced Client.

See Also