Previous Document Next Document

Object Model Reference : Classes : P : PatternCanvas : Properties : PatternCanvas.Height


PatternCanvas.Height

Property Height As Long

Description

Member of PatternCanvas

The Height property returns or specifies the vertical size of a pattern canvas. Allowed values range from 1 to 256 pixels.

VBA example

The following VBA example creates a small bitmap pattern that is 2 × 2 pixels in size. The upper-left and lower-right pixels are set to black, creating a checkerboard pattern.

Sub Test()
 Dim c As New PatternCanvas
 c.Width = 2
 c.Height = 2
 c.Clear
 c.PSet (0, 0)
 c.PSet (1, 1)
 With ActiveLayer.CreateRectangle(0, 0, 3, 3)
  .Fill.ApplyPatternFill cdrTwoColorPattern
  .Fill.Pattern.Canvas = c
 End With
End Sub

Previous Document Next Document Back to Top

Copyright 2013 Corel Corporation. All rights reserved.