cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Visit the PTCooler (the community lounge) to get to know your fellow community members and check out some of Dale's Friday Humor posts! X

Replace Linestyle Macro

jsvejkovksy
1-Visitor

Replace Linestyle Macro

Hey All,

I'm trying to write a macro that will replace a custom linestyle named "17-0.6-0.6" with the "Dotted" linestyle. I keep getting errors at "G = Activedoc.Styles[i].name". Does anyone know a solution? Here's what i have so far. I'm using IsoDraw 7.1.

Define S_QTY as integer

Define i as integer

Define G as string


S_QTY = Activedoc.styleCount

For i = 16 to S_QTY

G = Activedoc.Styles[i].name

If (G = "17-0.6-0.6")

If (exists (activeDoc.Styles["Dotted"]) = false) Then

Activedoc.Styles[i].name = "Dotted"

Else

Delete Styles G "Dotted"

i = (i - 1)

End If

S_QTY = Activedoc.styleCount

End for


End Macro



Thanks in advance.

0 REPLIES 0
Announcements

Top Tags