<?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: Convert Autocad Color Index TO/FROM ARGB in .NET Forum</title>
    <link>https://forums.autodesk.com/t5/net-forum/convert-autocad-color-index-to-from-argb/m-p/6420423#M35464</link>
    <description>Does this help any? Check the link in post 4 also.&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://forums.autodesk.com/t5/net/problems-with-rgb-and-color-index/td-p/3715706" target="_blank"&gt;http://forums.autodesk.com/t5/net/problems-with-rgb-and-color-index/td-p/3715706&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
    <pubDate>Tue, 05 Jul 2016 21:55:33 GMT</pubDate>
    <dc:creator>rkmcswain</dc:creator>
    <dc:date>2016-07-05T21:55:33Z</dc:date>
    <item>
      <title>Convert Autocad Color Index TO/FROM ARGB</title>
      <link>https://forums.autodesk.com/t5/net-forum/convert-autocad-color-index-to-from-argb/m-p/6420308#M35463</link>
      <description>&lt;P&gt;Hi, i need store Layers colors outside Autocad and return a new color.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I want a example to convert aci to/from System.Drawing.Color&amp;nbsp;ARGB.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thanks&lt;/P&gt;</description>
      <pubDate>Tue, 05 Jul 2016 20:35:50 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/convert-autocad-color-index-to-from-argb/m-p/6420308#M35463</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-07-05T20:35:50Z</dc:date>
    </item>
    <item>
      <title>Re: Convert Autocad Color Index TO/FROM ARGB</title>
      <link>https://forums.autodesk.com/t5/net-forum/convert-autocad-color-index-to-from-argb/m-p/6420423#M35464</link>
      <description>Does this help any? Check the link in post 4 also.&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://forums.autodesk.com/t5/net/problems-with-rgb-and-color-index/td-p/3715706" target="_blank"&gt;http://forums.autodesk.com/t5/net/problems-with-rgb-and-color-index/td-p/3715706&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 05 Jul 2016 21:55:33 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/convert-autocad-color-index-to-from-argb/m-p/6420423#M35464</guid>
      <dc:creator>rkmcswain</dc:creator>
      <dc:date>2016-07-05T21:55:33Z</dc:date>
    </item>
    <item>
      <title>Re: Convert Autocad Color Index TO/FROM ARGB</title>
      <link>https://forums.autodesk.com/t5/net-forum/convert-autocad-color-index-to-from-argb/m-p/6422019#M35465</link>
      <description>&lt;P&gt;I try solutions at this post, but no one work well to me.&lt;/P&gt;&lt;P&gt;I implement this code to convert to System.drawing.color, and send to external routines.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;private System.Drawing.Color AcadColorAciToDrawingColor(Autodesk.AutoCAD.Colors.Color color)&lt;BR /&gt;{&lt;BR /&gt;byte aci = Convert.ToByte(color.ColorIndex);&lt;BR /&gt;int aRGB = EntityColor.LookUpRgb(aci);&lt;BR /&gt;byte[] ch = BitConverter.GetBytes(aRGB);&lt;BR /&gt;if (!BitConverter.IsLittleEndian) {&lt;BR /&gt;Array.Reverse(ch);&lt;BR /&gt;}&lt;BR /&gt;int r = ch[2];&lt;BR /&gt;int g = ch[1];&lt;BR /&gt;int b = ch[0];&lt;/P&gt;&lt;P&gt;return System.Drawing.Color.FromArgb(r,g, b);&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thanks&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>Wed, 06 Jul 2016 17:55:29 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/convert-autocad-color-index-to-from-argb/m-p/6422019#M35465</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-07-06T17:55:29Z</dc:date>
    </item>
  </channel>
</rss>

