Previous Document Next Document

Object Model Reference : Classes : B : Bitmap : Methods : Bitmap.SaveAs


Bitmap.SaveAs

Function SaveAs(FileName As String, Filter As cdrFilter, [Compression As cdrCompressionType = cdrCompressionNone]) As ExportFilter

Description

Member of Bitmap

The SaveAs method saves a bitmap to a specified file and returns an ExportFilter object.

Parameter
Description
FileName
Specifies the filename
Filter
Specifies the filter to apply
Compression
Specifies the compression to apply. This parameter is optional, and its default value is cdrCompressionNone (0).

VBA example

The following VBA example saves each bitmap on the active page in the BMP format.

Sub Test()
 Dim s As Shape
 Dim ex As ExportFilter
 For Each s In ActivePage.Shapes
  If s.Type = cdrBitmapShape Then
   Set ex = s.Bitmap.SaveAs("c:\" & s.StaticID & ".bmp", cdrBMP, _
     cdrCompressionRLE_LW)
   ex.Finish
  End If
 Next s
End Sub

Previous Document Next Document Back to Top

Copyright 2013 Corel Corporation. All rights reserved.