Saving and
Refreshing Objects

Many ISA administration COM objects have methods you can use to
save their settings to persistent storage or to refresh their
settings from values in persistent storage.

Saving Objects

The Save method stores all settings of an object in
persistent storage. It is important to note that you can save no
changes unless you call the Save method. For example, if you
change the value of a property, you must explicitly save the
changes to the object, or the change will not be written to
persistent storage.

In the following example, the change made to the name of the
schedule will not be saved until the Save method is called
on the last line of code.

Note Some objects do not have a
Save method. To save these objects, invoke the Save
method of a parent of the object in the hierarchy. An example of
this is the FPCCacheDrives.Save method.

Refreshing Objects

If you need to abandon changes you've made to an object — while
preserving the object in memory — use the Refresh method.
The Refresh method reads the last saved values from
persistent storage and applies them to the object and its
subordinate objects.

The Refresh method retrieves and applies the last saved
settings for an object and any subordinate objects. Use the
Refresh method to be sure you have the current values for an
object and its subordinate objects.

The Refresh method overwrites any changes made but not
saved when it applies values from persistent storage. This can be
useful when you want to cancel changes that have been made but not
yet saved with the Save method.

In the following example the name of the schedule never changes
because the Save method is not called before the
Refresh method is called.