Hi guys,
I'm trying to get a vbscript to do this maybe easy task for some of you
I want to select 2 layers by name and then set the command :
NameA = "nomdeCalqueA"
NameB = "nomdeCalqueB"
Set appRef = CreateObject("Illustrator.Application")
Set idoc = appRef.ActiveDocument
appRef.activeDocument.Selection = Empty
For Each targetDocument In appRef.Documents
countOfLayers = targetDocument.Layers.Count
For layerIndex = countOfLayers To 1 Step -1
Set targetLayer = targetDocument.Layers(layerIndex)
layerName = targetLayer.Name
If (InStr(layerName, NameA) = 1) Then
'then select my layer
End If
If (InStr(layerName, NameB) = 1) Then
'then select my layer
End If
Next
Next
appRef.executeMenuCommand ("makeMask")
I'm a little lost...
Thank you for helping.
Nems.