1 Reply Latest reply on Sep 20, 2016 3:44 AM by TomVbk

    I can't create a rasterizeOptions object in vbscript


      Hi, newbie for illustrator scripting here

      I'm using vbscript because i'm used to program with this language.


      I'm trying to make a vbscript for illustrator cc that selects all content on a layer named "test" and rasterizes it with a few settings.

      I can't figure out how to use the "RasterizeOptions" class, I use vbsedit to browse trough the objects but from the moment I try:




      I get the error it can't make the object? How else should I create a RasterizeOptions object?

      What am i doing wrong here, can anyone show me an example?



      Regards, Tom

        • 1. Re: I can't create a rasterizeOptions object in vbscript
          TomVbk Level 1

          I was hoping for a more quick reaction because I need this fixed on Wednesday :\

          this is my script:


          Set appRef = CreateObject("Illustrator.Application")

          Set docRef = appRef.ActiveDocument

          docref.Layers.Item("test").HasSelectedArtwork = True


          Set rasterizeOptions = CreateObject("Illustrator.RasterizeOptions") '<--- cant create activeX object!?

          rasterizeOptions.padding = 0

          rasterizeOptions.resolution = 72

          rasterizeOptions.transparency = true

          call docref.rasterize(selectedItems, selectedItems.controlBounds,rasterizeOptions)


          I hope someone can help me