Copy link to clipboard
Copied
Dim myApp As New Illustrator.Application
Dim myDoc As Illustrator.Document
myDoc = myApp.ActiveDocument
Dim textRef = myDoc.TextFrames.Add
For Each ArtPageItems In myDoc.PageItems
If TypeName(ArtPageItems) = "TextFrame" Then
'========It is necessary to obtain the coordinates of the text block and move closer to the object (ie the text)============
Else
End If
Next
to get the the coordinates do
If TypeName(ArtPageItems) = "TextFrame" Then
x = ArtPageItems.Left
y = ArtPageItems.Top
Else
Copy link to clipboard
Copied
to get the the coordinates do
If TypeName(ArtPageItems) = "TextFrame" Then
x = ArtPageItems.Left
y = ArtPageItems.Top
Else
Copy link to clipboard
Copied
Thank you for your reply.
Tell me please, but as you can get closer to an object knowing its coordinates.
Copy link to clipboard
Copied
Hi Todd, you're welcome, please explain better, I don't understand the question.
are you trying to "move" a textframe (Dim textRef = myDoc.TextFrames.Add) closer to other text frames? or do you want to "zoom" to this textframe?
Find more inspiration, events, and resources on the new Adobe Community
Explore Now