Object Model Reference : Classes : S : StructExportOptions : Properties : StructExportOptions.Overwrite |
Property Overwrite As Boolean
Member of StructExportOptions
The Overwrite property returns or specifies whether an existing file with the specified name is overwritten. The default value of this property is True. If a file with the given name already exists and this property is set to False, the export operation fails.
The following VBA example fails while exporting the active document if the file img.gif already exists in the folder C:\Temp.
Sub Test() |
Dim opt As New StructExportOptions |
Dim flt As ExportFilter |
opt.Overwrite = False |
Set flt = ActiveDocument.ExportEx("C:\Temp\img.gif", cdrGIF, cdrCurrentPage, opt) |
flt.Finish |
End Sub |
Copyright 2013 Corel Corporation. All rights reserved.