<?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: Parallelism for reading drawing data using AccoreConsole in .NET Forum</title>
    <link>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6065146#M36979</link>
    <description>&lt;P&gt;To my knowledge you can start a max of 2 AutoCAD processes using one license.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.cadforum.cz/cadforum_en/qaID.asp?tip=5327" target="_blank"&gt;http://www.cadforum.cz/cadforum_en/qaID.asp?tip=5327&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Arial, Helvetica" size="2"&gt;On the same PC, you can run at same time (concurrently) up to 32 local AutoCAD licenses. &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 02 Mar 2016 08:07:11 GMT</pubDate>
    <dc:creator>SENL1362</dc:creator>
    <dc:date>2016-03-02T08:07:11Z</dc:date>
    <item>
      <title>Parallelism for reading drawing data using AccoreConsole</title>
      <link>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6062384#M36977</link>
      <description>&lt;P&gt;Hello All,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I want to process multiple drawings and read objects from each of the drawings.&lt;/P&gt;&lt;P&gt;I am using C#.NET as my programming language.&lt;/P&gt;&lt;P&gt;As there are 1000's of drawings, I am using&amp;nbsp;Parallel for each loop.&lt;/P&gt;&lt;P&gt;Inside the&amp;nbsp;loop I am invoking the AccoreConsole to do this.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;But, I am getting the error message as shown below:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;P&gt;Title: Licensing Error&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;------------------------------------------------------------------------------------------------&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Unable to Initialize adlm:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Internal Error Message: &amp;lt;Error initializing the usage tracking component.&amp;gt;&lt;/P&gt;&lt;P&gt;Error Code: &amp;lt;-104&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;------------------------------------------------------------------------------------------------&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Any help would be greatly appreciated.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Thanks in Advance,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Adarsh Jain Jinadev&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 29 Feb 2016 21:10:51 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6062384#M36977</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-02-29T21:10:51Z</dc:date>
    </item>
    <item>
      <title>Re: Parallelism for reading drawing data using AccoreConsole</title>
      <link>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6064611#M36978</link>
      <description>&lt;P&gt;Sample code which causes the issue is shown below for your reference:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;string[] files = Directory.GetFiles(@"C:\FDM\TestDrawings\", "*.dwg");&lt;BR /&gt;Parallel.ForEach(&lt;BR /&gt;files,&lt;BR /&gt;file =&amp;gt; {&lt;BR /&gt;{&lt;BR /&gt;Console.WriteLine("Processing started for : {0}", file);&lt;/P&gt;&lt;P&gt;using (Process process = new Process()) {&lt;BR /&gt;process.StartInfo.WorkingDirectory =&lt;BR /&gt;Path.GetDirectoryName(@"C:\Program Files\Autodesk\AutoCAD 2014\accoreconsole.exe");&lt;/P&gt;&lt;P&gt;process.StartInfo.UseShellExecute = false;&lt;BR /&gt;process.StartInfo.RedirectStandardOutput = true;&lt;BR /&gt;process.StartInfo.CreateNoWindow = true;&lt;/P&gt;&lt;P&gt;// parameters to execute the script file&lt;BR /&gt;process.StartInfo.FileName =&lt;BR /&gt;@"C:\Program Files\Autodesk\AutoCAD 2014\accoreconsole.exe";&lt;/P&gt;&lt;P&gt;process.StartInfo.Arguments = string.Empty;&lt;/P&gt;&lt;P&gt;// run it!&lt;BR /&gt;process.Start();&lt;BR /&gt;StreamReader outputStream = process.StandardOutput;&lt;BR /&gt;string output = outputStream.ReadToEnd();&lt;BR /&gt;output = output.Replace("\0", string.Empty);&lt;BR /&gt;outputStream.Close();&lt;BR /&gt;}&lt;BR /&gt;Console.WriteLine("Processing ended for : {0}", file);&lt;BR /&gt;}&lt;BR /&gt;});&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks and regards,&lt;/P&gt;&lt;P&gt;Adarsh Jain Jinadev&lt;/P&gt;</description>
      <pubDate>Tue, 01 Mar 2016 21:49:18 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6064611#M36978</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-03-01T21:49:18Z</dc:date>
    </item>
    <item>
      <title>Re: Parallelism for reading drawing data using AccoreConsole</title>
      <link>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6065146#M36979</link>
      <description>&lt;P&gt;To my knowledge you can start a max of 2 AutoCAD processes using one license.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.cadforum.cz/cadforum_en/qaID.asp?tip=5327" target="_blank"&gt;http://www.cadforum.cz/cadforum_en/qaID.asp?tip=5327&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Arial, Helvetica" size="2"&gt;On the same PC, you can run at same time (concurrently) up to 32 local AutoCAD licenses. &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 02 Mar 2016 08:07:11 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6065146#M36979</guid>
      <dc:creator>SENL1362</dc:creator>
      <dc:date>2016-03-02T08:07:11Z</dc:date>
    </item>
    <item>
      <title>Re: Parallelism for reading drawing data using AccoreConsole</title>
      <link>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6202518#M36980</link>
      <description>&lt;P&gt;Thanks for the answer. I am able to run 2 instances of AccoreConsole.exe in parallel.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I could&amp;nbsp;execute more than 2 instances of acad.exe in parallel, winout any license issue.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is the license limitation only for accoreconsole process?&lt;/P&gt;</description>
      <pubDate>Mon, 07 Mar 2016 14:56:42 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6202518#M36980</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-03-07T14:56:42Z</dc:date>
    </item>
    <item>
      <title>Re: Parallelism for reading drawing data using AccoreConsole</title>
      <link>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6202590#M36981</link>
      <description>I don't know.&lt;BR /&gt;According to the CadForum limited to 32 instances of Acad presumable also for the Console version.&lt;BR /&gt;</description>
      <pubDate>Mon, 07 Mar 2016 15:25:48 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6202590#M36981</guid>
      <dc:creator>SENL1362</dc:creator>
      <dc:date>2016-03-07T15:25:48Z</dc:date>
    </item>
    <item>
      <title>Re: Parallelism for reading drawing data using AccoreConsole</title>
      <link>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6202680#M36982</link>
      <description>&lt;P&gt;I have to question the contents of that link, such as they are.&amp;nbsp; Nothing more than a single sentence, no references, no links, nothing to support or corroborate&amp;nbsp;the statement.&lt;/P&gt;</description>
      <pubDate>Mon, 07 Mar 2016 15:59:53 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6202680#M36982</guid>
      <dc:creator>dgorsman</dc:creator>
      <dc:date>2016-03-07T15:59:53Z</dc:date>
    </item>
    <item>
      <title>Re: Parallelism for reading drawing data using AccoreConsole</title>
      <link>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6202968#M36983</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It seems to me that without calling WaitForExit() on each started process, your code try to start simultaneously as many process as they're file in the fles collection (it will be the same with 'simple' foreach loop).&lt;/P&gt;</description>
      <pubDate>Mon, 07 Mar 2016 18:33:48 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6202968#M36983</guid>
      <dc:creator>_gile</dc:creator>
      <dc:date>2016-03-07T18:33:48Z</dc:date>
    </item>
    <item>
      <title>Re: Parallelism for reading drawing data using AccoreConsole</title>
      <link>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6203037#M36984</link>
      <description>&lt;P&gt;I have my original code with WaitForExit(5000);&amp;nbsp;&lt;/P&gt;&lt;P&gt;Still i get the license issue if i start more than 2 processes in parallel.&lt;/P&gt;</description>
      <pubDate>Mon, 07 Mar 2016 18:32:23 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6203037#M36984</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-03-07T18:32:23Z</dc:date>
    </item>
    <item>
      <title>Re: Parallelism for reading drawing data using AccoreConsole</title>
      <link>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6203204#M36985</link>
      <description>&lt;P&gt;One other thing, it looks like you start accoreconsole processes but do not run any command or script:&lt;/P&gt;
&lt;PRE&gt;process.StartInfo.Arguments = string.Empty;&lt;/PRE&gt;</description>
      <pubDate>Mon, 07 Mar 2016 19:44:54 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6203204#M36985</guid>
      <dc:creator>_gile</dc:creator>
      <dc:date>2016-03-07T19:44:54Z</dc:date>
    </item>
    <item>
      <title>Re: Parallelism for reading drawing data using AccoreConsole</title>
      <link>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6222914#M36986</link>
      <description>&lt;P&gt;Could any body answer how to install 2 AutoCAD standalone licenses on the same computer?&lt;/P&gt;</description>
      <pubDate>Fri, 18 Mar 2016 13:47:41 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6222914#M36986</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-03-18T13:47:41Z</dc:date>
    </item>
    <item>
      <title>Re: Parallelism for reading drawing data using AccoreConsole</title>
      <link>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6227974#M36987</link>
      <description>&lt;P&gt;To avoid licence problems, why don't you just parallelize two (or more) tasks inside a single AcCoreConsole?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Something like:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;SPAN&gt;Parallel&lt;/SPAN&gt;.Invoke(()&amp;nbsp;=&amp;gt;&amp;nbsp;{&amp;nbsp;CheckDwg(filelist1);&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;gt;&amp;nbsp;{&amp;nbsp;CheckDwg(filelist2);&amp;nbsp;}
);&lt;/PRE&gt;&lt;P&gt;Inside CheskDwg() you can use Database.ReadDwgFile() function to read dwg content and do whatever you need.&lt;/P&gt;&lt;P&gt;You can make some tests and verify the speed gain you got with two, three or four parallel tasks...&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 22 Mar 2016 10:48:20 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/parallelism-for-reading-drawing-data-using-accoreconsole/m-p/6227974#M36987</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-03-22T10:48:20Z</dc:date>
    </item>
  </channel>
</rss>

