<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Tony don't know how make Commandline.vb  works in .NET Forum</title>
    <link>https://forums.autodesk.com/t5/net-forum/tony-don-t-know-how-make-commandline-vb-works/m-p/2862940#M62604</link>
    <description>&lt;PRE&gt;Thanks You for all help Frits.&lt;/PRE&gt;&lt;PRE&gt;The code you gave me needed some fxing,which might be usedful for others. &lt;/PRE&gt;&lt;PRE&gt;Below is the working Code. Thanks again to you and Tony. &lt;/PRE&gt;&lt;PRE&gt;Imports System.IO
Imports Autodesk.AutoCAD.Interop.Common
Imports System.Security
Imports System.Security.Permissions
Imports Autodesk.AutoCAD.Runtime
Imports Autodesk.AutoCAD.ApplicationServices
Imports Autodesk.AutoCAD
Imports Autodesk.AutoCAD.ApplicationServices.Application
Imports Autodesk.AutoCAD.DatabaseServices
Imports Autodesk.AutoCAD.EditorInput
Imports Autodesk.AutoCAD.Geometry
Imports Autodesk.AutoCAD.Windows
Imports Autodesk.AutoCAD.LayerManager
Imports Autodesk.AutoCAD.DatabaseServices





 Public Sub EdAtt()
        Dim dWG As Document = DocumentManager.MdiActiveDocument
        Dim selBlks As New SelectionFilter(New TypedValue() {New TypedValue(DxfCode.Start, "INSERT")})
        Dim selRes As PromptSelectionResult = dWG.Editor.GetSelection(selBlks)
        If selRes.Status = PromptStatus.OK Then
            Using tRans As Transaction = dWG.TransactionManager.StartTransaction
                For Each insID As ObjectId In selRes.Value.GetObjectIds
                    Dim theIns As Entity = insID.GetObject(OpenMode.ForWrite)
                    CommandLine.Command("_.EATTEDIT", insID, "")
                Next
                tRans.Commit()
            End Using

            dWG.Editor.Regen()
        End If
    End Sub&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 22 Dec 2010 15:55:38 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2010-12-22T15:55:38Z</dc:date>
    <item>
      <title>Tony don't know how make Commandline.vb  works</title>
      <link>https://forums.autodesk.com/t5/net-forum/tony-don-t-know-how-make-commandline-vb-works/m-p/2860728#M62598</link>
      <description>&lt;PRE&gt;&lt;P&gt;Tony,&lt;/P&gt;&lt;P&gt;in antoher thread you helped a gentleman to work with eattedit problem. I download the code and tried to use, since I have the same situation. But I could not  make it work. Could you please take a look.&lt;/P&gt;&lt;P&gt;the link was &lt;/P&gt;&lt;P&gt;&lt;A rel="nofollow" target="_blank" href="http://www.caddzone.com/CommandLine.vb"&gt;http://www.caddzone.com/CommandLine.vb&lt;/A&gt;&lt;/P&gt;&lt;P&gt;can you or somebody else help me please.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt; Sub neweditattribute()
        Dim Entry As Autodesk.AutoCAD.Interop.Common.AcadEntity
        Do While ThisDrawing.SelectionSets.Count &amp;lt;&amp;gt; 0
            ThisDrawing.SelectionSets.Item(0).Delete()
        Loop
        SelectionSet = ""
        sset = ThisDrawing.SelectionSets.Add("SS1")
        sset.SelectOnScreen()
        For Each Entry In sset
            If Entry.ObjectName = "AcDbBlockReference" Then
                TempT = Entry.ObjectID
                CommandLine.Command("_.EATTEDIT", Entry)
            End If
        Next
    End Sub&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 20 Dec 2010 17:52:35 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/tony-don-t-know-how-make-commandline-vb-works/m-p/2860728#M62598</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2010-12-20T17:52:35Z</dc:date>
    </item>
    <item>
      <title>Re: Tony don't know how make Commandline.vb  works</title>
      <link>https://forums.autodesk.com/t5/net-forum/tony-don-t-know-how-make-commandline-vb-works/m-p/2861278#M62599</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Put ,"" as the third argument in the command call as in:&lt;/P&gt;&lt;P&gt;CommandLine.Command("_.EATTEDIT", myObjID, "")&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Some improments you could make:&lt;/P&gt;&lt;P&gt;I: Let AutoCAD do the selection for you based on the object type, like so:&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;CommandMethod("EdAtt")&amp;gt; _&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Public Sub EdAtt()&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Dim dWG As Document = DocumentManager.MdiActiveDocument&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Dim selBlks As New SelectionFilter(New TypedValue() {New TypedValue(DxfCode.Start, "INSERT")})&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Dim selRes As PromptSelectionResult =dWG.Editor.GetSelection(selBlks)&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; If selRes.Status = PromptStatus.OK Then&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Using tRans As Transaction = theDWG.TransactionManager.StartTransaction&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; For Each insID As ObjectId In tRans.Value.GetObjectIds&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Dim theIns As Entity = insID.GetObject(OpenMode.ForWrite)&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; CommandLine.Command("_.EATTEDIT", insID, "")&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Next&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; myTRans.Commit()&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; End Using&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; myDWG.Editor.Regen()&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; End If&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; End Sub&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;II: Or use the PickFirst selection set like:&lt;/P&gt;&lt;P&gt;(But then you have to check for the entity type again.)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &amp;lt;CommandMethod("EdAtt2", CommandFlags.UsePickSet)&amp;gt; _&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Public Sub EdAtt2()&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Dim dWG As Document = DocumentManager.MdiActiveDocument&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Dim theEd As Editor =dWG.Editor&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Dim selRes As PromptSelectionResult = theEd.SelectImplied&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; If myPSR.Status = PromptStatus.OK Then&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 'AutoCAD 2011&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if selID.ObjectClass().DxfName="INSERT" then&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Dim selEnt As Entity = selID.GetObject(OpenMode.ForWrite)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 'AutoCAD 2008&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Dim selEnt As Entity = selID.GetObject(OpenMode.ForRead)&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if selEnt.GetType().Name="INSERT" then&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; selEnt.UpgradeOpen()&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 21 Dec 2010 09:27:31 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/tony-don-t-know-how-make-commandline-vb-works/m-p/2861278#M62599</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2010-12-21T09:27:31Z</dc:date>
    </item>
    <item>
      <title>Re: Tony don't know how make Commandline.vb  works</title>
      <link>https://forums.autodesk.com/t5/net-forum/tony-don-t-know-how-make-commandline-vb-works/m-p/2861804#M62600</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks Frits for comments, and sorry for touble. I am&amp;nbsp; learning this dot net just based on try and error.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1-&amp;nbsp; I made changes and put it as you said like&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;CommandLine.Command("_.EATTEDIT", myObjID, "")

&lt;/PRE&gt;&lt;P&gt;Get this error :&amp;nbsp;&amp;nbsp; Unsupported&amp;nbsp;type in Command() methor.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2- then &amp;nbsp;I&amp;nbsp;used &amp;nbsp;your suggested &amp;nbsp;improved code and as&amp;nbsp;you see I don't know how to declare&amp;nbsp;those types. see attached picture please. Could you please help me to declase those type variables first.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 21 Dec 2010 18:05:44 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/tony-don-t-know-how-make-commandline-vb-works/m-p/2861804#M62600</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2010-12-21T18:05:44Z</dc:date>
    </item>
    <item>
      <title>Re: Tony don't know how make Commandline.vb  works</title>
      <link>https://forums.autodesk.com/t5/net-forum/tony-don-t-know-how-make-commandline-vb-works/m-p/2861978#M62601</link>
      <description>&lt;P&gt;Of course i will help you that's our purpose on these forums&lt;/P&gt;&lt;P&gt;However i too have just a few days of .net experience i can't over you to much help&lt;/P&gt;&lt;P&gt;I would send you my project but i am at home now without the required .net source&lt;/P&gt;&lt;P&gt;And with a few days work out of office the earliest occasion will be Friday.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So these tips are suggestions without tests:&lt;/P&gt;&lt;P&gt;1. you probably forgot to add (all) the Autodesk import lines on top of your class&lt;/P&gt;&lt;P&gt;2. did you add the tony class to your project ?&lt;/P&gt;&lt;P&gt;3. did you wrap your EdAtt command in the main class ?&lt;/P&gt;&lt;P&gt;4. did you buy and read a good VB.net/AutoCAD book ? If not i can recommend you one.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;Hope this helps to solve some of your problems or else see you on Friday.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 21 Dec 2010 19:48:47 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/tony-don-t-know-how-make-commandline-vb-works/m-p/2861978#M62601</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2010-12-21T19:48:47Z</dc:date>
    </item>
    <item>
      <title>Re: Tony don't know how make Commandline.vb  works</title>
      <link>https://forums.autodesk.com/t5/net-forum/tony-don-t-know-how-make-commandline-vb-works/m-p/2862020#M62602</link>
      <description>&lt;PRE&gt;Thanks frits,&lt;/PRE&gt;&lt;PRE&gt;It would be nice of you , if I have a real running project using that commandline feature. So I can understand what is going on. I am waitng for that.In the mean time. I would answer your questions.&lt;FONT color="#ff0000"&gt;&lt;/FONT&gt;&lt;/PRE&gt;&lt;PRE&gt;&lt;FONT color="#333300"&gt;1.you probably forgot to add (all) the Autodesk import lines on top of your class&lt;/FONT&gt;&lt;P&gt;&lt;FONT color="#333300"&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#333300"&gt;This is what I import. Dont know what else should be here.&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#ff0000"&gt;Imports Autodesk.AutoCAD.Runtime&lt;BR /&gt;Imports Autodesk.AutoCAD.ApplicationServices&lt;BR /&gt;Imports System&lt;BR /&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#333300"&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#333300"&gt;2. did you add the tony class to your project ?  &lt;/FONT&gt;&lt;FONT color="#ff0000"&gt;Yes&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#333300"&gt;3. did you wrap your EdAtt command in the main class ? &lt;/FONT&gt;&lt;FONT color="#ff0000"&gt;Yes&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#333300"&gt;4. did you buy and read a good VB.net/AutoCAD book ? If not i can recommend you one.&lt;FONT color="#ff0000"&gt; Don't Have any&lt;/FONT&gt;.&lt;/FONT&gt;&lt;FONT color="#ff0000"&gt; Would be nice of you to let me know about the name of Book &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#333300"&gt;Regards,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 21 Dec 2010 20:14:25 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/tony-don-t-know-how-make-commandline-vb-works/m-p/2862020#M62602</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2010-12-21T20:14:25Z</dc:date>
    </item>
    <item>
      <title>Re: Tony don't know how make Commandline.vb  works</title>
      <link>https://forums.autodesk.com/t5/net-forum/tony-don-t-know-how-make-commandline-vb-works/m-p/2862062#M62603</link>
      <description>&lt;P&gt;The book is: VB.NET for AutoCAD 2010, Jerry Winters,&amp;nbsp; ebook(Thanks Jerry great book)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Some more Imports:&lt;/P&gt;&lt;P&gt;Imports Autodesk.AutoCAD&lt;BR /&gt;Imports Autodesk.AutoCAD.Runtime&lt;BR /&gt;Imports Autodesk.AutoCAD.ApplicationServices&lt;BR /&gt;Imports Autodesk.AutoCAD.ApplicationServices.Application&lt;BR /&gt;Imports Autodesk.AutoCAD.DatabaseServices&lt;BR /&gt;Imports Autodesk.AutoCAD.EditorInput&lt;BR /&gt;Imports Autodesk.AutoCAD.Geometry&lt;BR /&gt;Imports Autodesk.AutoCAD.Runtime&lt;BR /&gt;Imports Autodesk.AutoCAD.Windows&lt;BR /&gt;Imports Autodesk.AutoCAD.LayerManager&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;There are&amp;nbsp; 2&amp;nbsp; more but for now that are specials&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 21 Dec 2010 20:31:54 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/tony-don-t-know-how-make-commandline-vb-works/m-p/2862062#M62603</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2010-12-21T20:31:54Z</dc:date>
    </item>
    <item>
      <title>Re: Tony don't know how make Commandline.vb  works</title>
      <link>https://forums.autodesk.com/t5/net-forum/tony-don-t-know-how-make-commandline-vb-works/m-p/2862940#M62604</link>
      <description>&lt;PRE&gt;Thanks You for all help Frits.&lt;/PRE&gt;&lt;PRE&gt;The code you gave me needed some fxing,which might be usedful for others. &lt;/PRE&gt;&lt;PRE&gt;Below is the working Code. Thanks again to you and Tony. &lt;/PRE&gt;&lt;PRE&gt;Imports System.IO
Imports Autodesk.AutoCAD.Interop.Common
Imports System.Security
Imports System.Security.Permissions
Imports Autodesk.AutoCAD.Runtime
Imports Autodesk.AutoCAD.ApplicationServices
Imports Autodesk.AutoCAD
Imports Autodesk.AutoCAD.ApplicationServices.Application
Imports Autodesk.AutoCAD.DatabaseServices
Imports Autodesk.AutoCAD.EditorInput
Imports Autodesk.AutoCAD.Geometry
Imports Autodesk.AutoCAD.Windows
Imports Autodesk.AutoCAD.LayerManager
Imports Autodesk.AutoCAD.DatabaseServices





 Public Sub EdAtt()
        Dim dWG As Document = DocumentManager.MdiActiveDocument
        Dim selBlks As New SelectionFilter(New TypedValue() {New TypedValue(DxfCode.Start, "INSERT")})
        Dim selRes As PromptSelectionResult = dWG.Editor.GetSelection(selBlks)
        If selRes.Status = PromptStatus.OK Then
            Using tRans As Transaction = dWG.TransactionManager.StartTransaction
                For Each insID As ObjectId In selRes.Value.GetObjectIds
                    Dim theIns As Entity = insID.GetObject(OpenMode.ForWrite)
                    CommandLine.Command("_.EATTEDIT", insID, "")
                Next
                tRans.Commit()
            End Using

            dWG.Editor.Regen()
        End If
    End Sub&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 22 Dec 2010 15:55:38 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/tony-don-t-know-how-make-commandline-vb-works/m-p/2862940#M62604</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2010-12-22T15:55:38Z</dc:date>
    </item>
    <item>
      <title>Re: Tony don't know how make Commandline.vb  works</title>
      <link>https://forums.autodesk.com/t5/net-forum/tony-don-t-know-how-make-commandline-vb-works/m-p/2863150#M62605</link>
      <description>&lt;P&gt;Youre welcome&lt;/P&gt;</description>
      <pubDate>Wed, 22 Dec 2010 18:02:09 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/tony-don-t-know-how-make-commandline-vb-works/m-p/2863150#M62605</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2010-12-22T18:02:09Z</dc:date>
    </item>
  </channel>
</rss>

