你好
我编写了一个程序来获取选定维度的les值。
我使用。测量方法,但他给了我尺寸的真实值。
有一种方法可以获取维度的“showing”值。
例如:101 3/4而不是101.7756889
[size=2][color=#0000ff][size=2][color=#0000ff]Dim[/color][/size][/color][/size][size=2] MYDOCUMENT [/size][size=2][color=#0000ff][size=2][color=#0000ff]As[/color][/size][/color][/size][size=2] Document = DocumentManager.MdiActiveDocument[/size][size=2][color=#0000ff][size=2][color=#0000ff]Dim[/color][/size][/color][/size][size=2] MYED [/size][size=2][color=#0000ff][size=2][color=#0000ff]As[/color][/size][/color][/size][size=2] Editor = MYDOCUMENT.Editor[/size][size=2][color=#0000ff][size=2][color=#0000ff]Using[/color][/size][/color][/size][size=2] MYTRANS [/size][size=2][color=#0000ff][size=2][color=#0000ff]As[/color][/size][/color][/size][size=2] Transaction = MYDOCUMENT.TransactionManager.StartTransaction[/size][size=2][color=#0000ff][size=2][color=#0000ff]Me[/color][/size][/color][/size][size=2].Hide()[/size][size=2][color=#0000ff][size=2][color=#0000ff]Dim[/color][/size][/color][/size][size=2] MYPSR [/size][size=2][color=#0000ff][size=2][color=#0000ff]As[/color][/size][/color][/size][size=2] PromptEntityResult = MYED.GetEntity([/size][size=2][color=#a31515][size=2][color=#a31515]"CHOISIS UNE COTE"[/color][/size][/color][/size][size=2])[/size][size=2][color=#0000ff][size=2][color=#0000ff]If[/color][/size][/color][/size][size=2] IsNothing(MYPSR.Status) = [/size][size=2][color=#0000ff][size=2][color=#0000ff]False[/color][/size][/color][/size][size=2][color=#0000ff][size=2][color=#0000ff]Then[/color][/size][/color][/size][size=2]MYOBJID = MYPSR.ObjectId[/size][size=2][color=#0000ff][size=2][color=#0000ff]If[/color][/size][/color][/size][size=2] MYOBJID.IsNull = [/size][size=2][color=#0000ff][size=2][color=#0000ff]True[/color][/size][/color][/size][size=2][color=#0000ff][size=2][color=#0000ff]Then[/color][/size][/color][/size][size=2][color=#0000ff][size=2][color=#0000ff]Exit[/color][/size][/color][/size][size=2][color=#0000ff][size=2][color=#0000ff]Sub[/color][/size][/color][/size][size=2][color=#0000ff][size=2][color=#0000ff]Dim[/color][/size][/color][/size][size=2] MYCOTE [/size][size=2][color=#0000ff][size=2][color=#0000ff]As[/color][/size][/color][/size][size=2] Dimension[/size][size=2]MYCOTE = MYOBJID.GetObject(OpenMode.ForRead)[/size][size=2][color=#0000ff][size=2][color=#0000ff]Dim[/color][/size][/color][/size][size=2] TEXTE [/size][size=2][color=#0000ff][size=2][color=#0000ff]As[/color][/size][/color][/size][size=2][color=#0000ff][size=2][color=#0000ff]String[/color][/size][/color][/size][size=2] = MYCOTE.Measurement[/size][size=2]MsgBox(TEXTE)[/size][size=2][color=#0000ff][size=2][color=#0000ff]End[/color][/size][/color][/size][size=2][color=#0000ff][size=2][color=#0000ff]If[/color][/size][/color][/size][size=2][color=#0000ff][size=2][color=#0000ff]End[/color][/size][/color][/size][size=2][color=#0000ff][size=2][color=#0000ff]Using[/color][/size][/color][/size]