Hi, Thank you. That takes care of the error I get stating that the Set dlg = ui.ModalDialog is incorrect But now I get an error message that the Function transform3(scope,transformation,source) has a syntax error, but don't see why. This is what I have: Sub Main Document.ComponentSet("Roads Master 2").Open Set ui = Application.UserInterface ui.InvokeCommand "DrawingTransformBuffers" Set dlg = ui.ModalDialog dlg.ControlSet("EditTransformTarget").Text = "[All Objects]" dlg.ControlSet("EditTransformOperation").Text = "Buffers" dlg.ControlSet("EditTransformSource").Value = "3" dlg.ControlSet("EditTransformApply").Value = "TRUE" dlg.Accept transform3 "[All Objects in Roads Master 2]","Buffers","3" Function transform3(scope,transformation,source) Set ui = Application.UserInterface With ui.toolbars("Transform").ControlSet .item("EditTransformTarget").Text = scope .item("EditTransformOperation").Text = transformation .item("EditTransformSource").Text = source .item("EditTransformApply").Push End With End Function End Sub
|