I feel as though this should be relatively easy, but I keep getting an error. I'm trying to make a rule that looks at all dimensions in a drawing and changes the style for ones above a certain value, something like this...
For i=1 To DrawDoc.Sheets.Count For Each oDim In DrawDoc.Sheets.Item(i).DrawingDimensions If oDim.ModelValue <= 60*2.54 Then oDim.Style = "???" End If Next Next
I just can't seem to make it happen. The code loops though the dimensions just fine, but I haven't been able to change the style for each dimension. Can anyone give me a hint as to what it should look like?
Thanks.
Hi,
As usual the best starting point is if you try to achieve what you want through the UI and then investigate the objects through VBA:
http://adndevblog.typepad.com/manufacturing/2013/10/discover-object-model.html
If no luck, then list the UI steps that you want to automate through the API.
Cheers,