<?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: in VBA Forum</title>
    <link>https://forums.autodesk.com/t5/vba-forum/help-needed-opening-dwg-from-vb6-in-a2k/m-p/337124#M98903</link>
    <description>Thank you Frank&lt;BR /&gt;
It works fine now, opens the drawing and ..Crash!.."Unhendled  Exemption&lt;BR /&gt;
in fffff......."&lt;BR /&gt;
What I've been getting so often recently.&lt;BR /&gt;
We had A2K installed 3 weeks ago.&lt;BR /&gt;
&lt;BR /&gt;
Thank you again for your help&lt;BR /&gt;
&lt;BR /&gt;
--&lt;BR /&gt;
Val Iliev&lt;BR /&gt;
valentin@canada.com</description>
    <pubDate>Fri, 15 Oct 1999 17:29:00 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>1999-10-15T17:29:00Z</dc:date>
    <item>
      <title>Help needed Opening dwg from VB6 in A2K</title>
      <link>https://forums.autodesk.com/t5/vba-forum/help-needed-opening-dwg-from-vb6-in-a2k/m-p/337120#M98899</link>
      <description>I am starting to learn VB6 for Acad2000 and have some experience in VB.&lt;BR /&gt;
&lt;BR /&gt;
Please could somebody help me how can I open a particular drawing from&lt;BR /&gt;
VB6 in Autocad2000,&lt;BR /&gt;
including all References, Dim's I have to do.&lt;BR /&gt;
&lt;BR /&gt;
Thank you in advance&lt;BR /&gt;
--&lt;BR /&gt;
Val Iliev&lt;BR /&gt;
valentin@canada.com</description>
      <pubDate>Fri, 15 Oct 1999 15:34:16 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vba-forum/help-needed-opening-dwg-from-vb6-in-a2k/m-p/337120#M98899</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>1999-10-15T15:34:16Z</dc:date>
    </item>
    <item>
      <title>Re: Help needed Opening dwg from VB6 in A2K</title>
      <link>https://forums.autodesk.com/t5/vba-forum/help-needed-opening-dwg-from-vb6-in-a2k/m-p/337121#M98900</link>
      <description>Be sure to include a reference to the AutoCAD 2000 object type library in&lt;BR /&gt;
your project. Place a command button on your form and double-click it. Use&lt;BR /&gt;
this code as a guide:&lt;BR /&gt;
&lt;BR /&gt;
Dim acadApp as AcadApplication&lt;BR /&gt;
&lt;BR /&gt;
On Error Resume Next&lt;BR /&gt;
Set acadApp  = GetObject(,"AutoCAD.Application")&lt;BR /&gt;
If err then set acadApp = CreateObject("AutoCAD.Application")&lt;BR /&gt;
If err then&lt;BR /&gt;
    msgbox "Couldn't connect to AutoCAD!", vbCritical&lt;BR /&gt;
    end&lt;BR /&gt;
else&lt;BR /&gt;
    acadApp.Documents.Open &lt;PUT your="" drawing="" file="" path="" here=""&gt;&lt;BR /&gt;
end if&lt;BR /&gt;
&lt;BR /&gt;
Of course you'd probably want to use a dialog to get the file from a user&lt;BR /&gt;
but the method remains the same.&lt;BR /&gt;
&lt;BR /&gt;
Val Iliev &lt;ENG&gt; wrote in message&lt;BR /&gt;
news:38074978.622085F1@berg-group.com...&lt;BR /&gt;
&amp;gt; I am starting to learn VB6 for Acad2000 and have some experience in VB.&lt;BR /&gt;
&amp;gt;&lt;BR /&gt;
&amp;gt; Please could somebody help me how can I open a particular drawing from&lt;BR /&gt;
&amp;gt; VB6 in Autocad2000,&lt;BR /&gt;
&amp;gt; including all References, Dim's I have to do.&lt;BR /&gt;
&amp;gt;&lt;BR /&gt;
&amp;gt; Thank you in advance&lt;BR /&gt;
&amp;gt; --&lt;BR /&gt;
&amp;gt; Val Iliev&lt;BR /&gt;
&amp;gt; valentin@canada.com&lt;BR /&gt;
&amp;gt;&lt;BR /&gt;
&amp;gt;&lt;/ENG&gt;&lt;/PUT&gt;</description>
      <pubDate>Fri, 15 Oct 1999 16:01:16 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vba-forum/help-needed-opening-dwg-from-vb6-in-a2k/m-p/337121#M98900</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>1999-10-15T16:01:16Z</dc:date>
    </item>
    <item>
      <title>Re:</title>
      <link>https://forums.autodesk.com/t5/vba-forum/help-needed-opening-dwg-from-vb6-in-a2k/m-p/337122#M98901</link>
      <description>Hi Frank&lt;BR /&gt;
&lt;BR /&gt;
Thank you for your help, but this is what happens when I ran the code.&lt;BR /&gt;
&lt;BR /&gt;
1.It opens drawing name - Drawing1.dwg in the App.Path where VB6.EXE is.&lt;BR /&gt;
&lt;BR /&gt;
2.The Error Message you specified comes up.&lt;BR /&gt;
&lt;BR /&gt;
Any suggestions?&lt;BR /&gt;
&lt;BR /&gt;
Thank you&lt;BR /&gt;
&lt;BR /&gt;
--&lt;BR /&gt;
Val Iliev&lt;BR /&gt;
valentin@canada.com</description>
      <pubDate>Fri, 15 Oct 1999 16:31:37 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vba-forum/help-needed-opening-dwg-from-vb6-in-a2k/m-p/337122#M98901</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>1999-10-15T16:31:37Z</dc:date>
    </item>
    <item>
      <title>Re:</title>
      <link>https://forums.autodesk.com/t5/vba-forum/help-needed-opening-dwg-from-vb6-in-a2k/m-p/337123#M98902</link>
      <description>Oops. In the first if statement, I forgot to clear the error object.&lt;BR /&gt;
This -&amp;gt;If err then set acadApp = CreateObject("AutoCAD.Application")&lt;BR /&gt;
Should be this:&lt;BR /&gt;
If err then&lt;BR /&gt;
    err.clear&lt;BR /&gt;
    set acadApp = CreateObject("AutoCAD.Application")&lt;BR /&gt;
end if&lt;BR /&gt;
&lt;BR /&gt;
Also, it would be best to delcare the acadApp variable in the declarations&lt;BR /&gt;
section of your form so you can keep a reference to the AutoCAD object for&lt;BR /&gt;
the life of your app.&lt;BR /&gt;
&lt;BR /&gt;
Val Iliev &lt;ENG&gt; wrote in message&lt;BR /&gt;
news:380756E9.CE557DCC@berg-group.com...&lt;BR /&gt;
&amp;gt; Hi Frank&lt;BR /&gt;
&amp;gt;&lt;BR /&gt;
&amp;gt; Thank you for your help, but this is what happens when I ran the code.&lt;BR /&gt;
&amp;gt;&lt;BR /&gt;
&amp;gt; 1.It opens drawing name - Drawing1.dwg in the App.Path where VB6.EXE is.&lt;BR /&gt;
&amp;gt;&lt;BR /&gt;
&amp;gt; 2.The Error Message you specified comes up.&lt;BR /&gt;
&amp;gt;&lt;BR /&gt;
&amp;gt; Any suggestions?&lt;BR /&gt;
&amp;gt;&lt;BR /&gt;
&amp;gt; Thank you&lt;BR /&gt;
&amp;gt;&lt;BR /&gt;
&amp;gt; --&lt;BR /&gt;
&amp;gt; Val Iliev&lt;BR /&gt;
&amp;gt; valentin@canada.com&lt;BR /&gt;
&amp;gt;&lt;BR /&gt;
&amp;gt;&lt;/ENG&gt;</description>
      <pubDate>Fri, 15 Oct 1999 16:54:38 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vba-forum/help-needed-opening-dwg-from-vb6-in-a2k/m-p/337123#M98902</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>1999-10-15T16:54:38Z</dc:date>
    </item>
    <item>
      <title>Re:</title>
      <link>https://forums.autodesk.com/t5/vba-forum/help-needed-opening-dwg-from-vb6-in-a2k/m-p/337124#M98903</link>
      <description>Thank you Frank&lt;BR /&gt;
It works fine now, opens the drawing and ..Crash!.."Unhendled  Exemption&lt;BR /&gt;
in fffff......."&lt;BR /&gt;
What I've been getting so often recently.&lt;BR /&gt;
We had A2K installed 3 weeks ago.&lt;BR /&gt;
&lt;BR /&gt;
Thank you again for your help&lt;BR /&gt;
&lt;BR /&gt;
--&lt;BR /&gt;
Val Iliev&lt;BR /&gt;
valentin@canada.com</description>
      <pubDate>Fri, 15 Oct 1999 17:29:00 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vba-forum/help-needed-opening-dwg-from-vb6-in-a2k/m-p/337124#M98903</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>1999-10-15T17:29:00Z</dc:date>
    </item>
  </channel>
</rss>

