UpdateFromFile Method

Applies To

Workbook Object.

Description

Updates a read-only workbook from the saved disk file version of the workbook if the disk version is more recent than the current copy of the workbook in memory. If the disk copy has not changed since the workbook was loaded, the in-memory copy of the workbook is not reloaded.

Syntax

object.UpdateFromFile

object

Required. The Workbook object.

Remarks

This method is useful when a workbook is opened as read-only by user A and read-write by user B. If user B saves a newer version of the workbook to disk while user A still has the workbook open, user A cannot get the updated copy without closing and reopening the workbook and losing view settings. The UpdateFromFile method updates the in-memory copy of the workbook from the disk file.

See Also

ChangeFileAccess Method.

Example

This example updates the active workbook.


ActiveWorkbook.UpdateFromFile