Previous Document Next Document

Object Model Reference : Classes : E : EffectEnvelope : Methods : EffectEnvelope.CopyFrom


EffectEnvelope.CopyFrom

Sub CopyFrom(Source As EffectEnvelope)

Description

Member of EffectEnvelope

The CopyFrom method copies the properties from one envelope effect to another.

If you’ve applied an effect to the object since you applied the envelope, you won’t be able to copy the envelope.

Parameter
Description
Source
Specifies the envelope effect from which to copy properties

VBA example

The following VBA example creates a text object and applies an envelope effect to it. It then creates a group of rectangles and applies an envelope to them, using the same parameters as the text’s envelope.

Sub Test()
 Dim s1 As Shape, s2 As Shape, eff As Effect
 Set s1 = ActiveLayer.CreateArtisticText(2.75, 5, "Text")
 With s1.Text.FontProperties
  .Name = "Arial Black"
  .Size = 150
 End With
 Set eff = s1.CreateEnvelope(3, cdrEnvelopePutty, True)
 Set s2 = ActiveLayer.CreateGridBoxes(0, 0, 3, 3, 8, 8)
 s2.CreateEnvelope(1).Envelope.CopyFrom eff.Envelope
End Sub

Previous Document Next Document Back to Top

Copyright 2013 Corel Corporation. All rights reserved.