View Single Post
Old 17-11-2003, 06:26
Posts: n/a
Default VBA problem in PP11

Hi, Alex.

I'm trying to translate a script into VBA, but I'm having big problems
I have 2 objects and I want to add a shadow to them:
(I cut the operation in small chunks just in order to try to find the errors)

dim L as Range
dim Lrange as Range
dim Lobj as ObjectLayer
dim Lds as DropShadow

Set Lrange = ActiveDocument.Layers.Paste   'copy the objects from clipboard
set L = Lrange.Combine()        'combines the 2 objects
z=IsObject(L)                          'TRUE: just added for debugging
L.Activate             'and here I get the error "object variable not set" (freely translated into english)
set Lobj = L.ObjectLayer        
set Lds = Lobj.DropShadow       'here I want to add the shadow

Lds.angle=10      'and here I will shurely get also an error as it is Read-only: how can I set the angle of the shadow?
Hope you can help me!
Reply With Quote