<?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   code From  Lisp  to  C-Sharp in Civil 3D Customization Forum</title>
    <link>https://forums.autodesk.com/t5/civil-3d-customization-forum/convert-code-from-lisp-to-c-sharp/m-p/10830945#M5979</link>
    <description>&lt;LI-CODE lang="general"&gt;        /// &amp;lt;summary&amp;gt;
        /// module must be "Land", "Pipe", "Roadway", or "Survey"
        /// &amp;lt;/summary&amp;gt;
        /// &amp;lt;param name="module"&amp;gt;&amp;lt;/param&amp;gt;
        /// &amp;lt;returns&amp;gt;AeccApp string&amp;lt;/returns&amp;gt;
        public static dynamic GetAeccApp(string module)
        {
            var rootkey = HostApplicationServices.Current.UserRegistryProductRootKey;
            var hj = Registry.LocalMachine.OpenSubKey(rootkey);
            var c3d = (string)hj.GetValue("Release");
            c3d = c3d.Substring(0, c3d.IndexOf(".", (c3d.IndexOf(".") + 1)));
            hj.Close();
            c3d = "AeccXUi" + module + ".Aecc" + (module == "Land" ? "" : module) + "Application." + c3d;
            dynamic acadApp = Application.AcadApplication;
            dynamic aeccApp = acadApp.GetInterfaceObject(c3d);
            return aeccApp;
        }
&lt;/LI-CODE&gt;</description>
    <pubDate>Sat, 18 Dec 2021 14:49:45 GMT</pubDate>
    <dc:creator>Jeff_M</dc:creator>
    <dc:date>2021-12-18T14:49:45Z</dc:date>
    <item>
      <title>convert   code From  Lisp  to  C-Sharp</title>
      <link>https://forums.autodesk.com/t5/civil-3d-customization-forum/convert-code-from-lisp-to-c-sharp/m-p/10830640#M5978</link>
      <description>&lt;P&gt;Hi how can convert&lt;BR /&gt;This code is from&lt;SPAN class=""&gt;&amp;nbsp; &lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/32637"&gt;@Jeff_M&lt;/a&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;From&amp;nbsp; Lisp&amp;nbsp; to&amp;nbsp; C-Sharp&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="csharp"&gt;https://forums.autodesk.com/t5/civil-3d-customization/create-cogo-point-using-lisp/td-p/8960247

(setq C3D (strcat "HKEY_LOCAL_MACHINE\\"
			     (if vlax-user-product-key
			       (vlax-user-product-key)
			       (vlax-product-key)
			     )
		     )
		 C3D (vl-registry-read C3D "Release")
		 C3D (substr
		       C3D
		       1
		       (vl-string-search
			 "."
			 C3D
			 (+ (vl-string-search "." C3D) 1)
		       )
		     ))&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;to get the number&amp;nbsp;for example&amp;nbsp; "13.4"&lt;/P&gt;&lt;P&gt;I came close to it, I did not know the origin of the solution&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;LI-CODE lang="general"&gt;https://www.theswamp.org/index.php?topic=43276.0 
// I got the "Software\Autodesk\AutoCAD\R19.0\ACAD-B001:409" value:
String _x = AcDb.HostApplicationServices.Current.MachineRegistryProductRootKey;
 
// I got the "Software\Autodesk\AutoCAD\R19.0\ACAD-B001:409" value:
String _y = AcDb.HostApplicationServices.Current.UserRegistryProductRootKey;
 &lt;/LI-CODE&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>Sat, 18 Dec 2021 08:06:08 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/civil-3d-customization-forum/convert-code-from-lisp-to-c-sharp/m-p/10830640#M5978</guid>
      <dc:creator>hosneyalaa</dc:creator>
      <dc:date>2021-12-18T08:06:08Z</dc:date>
    </item>
    <item>
      <title>Re: convert   code From  Lisp  to  C-Sharp</title>
      <link>https://forums.autodesk.com/t5/civil-3d-customization-forum/convert-code-from-lisp-to-c-sharp/m-p/10830945#M5979</link>
      <description>&lt;LI-CODE lang="general"&gt;        /// &amp;lt;summary&amp;gt;
        /// module must be "Land", "Pipe", "Roadway", or "Survey"
        /// &amp;lt;/summary&amp;gt;
        /// &amp;lt;param name="module"&amp;gt;&amp;lt;/param&amp;gt;
        /// &amp;lt;returns&amp;gt;AeccApp string&amp;lt;/returns&amp;gt;
        public static dynamic GetAeccApp(string module)
        {
            var rootkey = HostApplicationServices.Current.UserRegistryProductRootKey;
            var hj = Registry.LocalMachine.OpenSubKey(rootkey);
            var c3d = (string)hj.GetValue("Release");
            c3d = c3d.Substring(0, c3d.IndexOf(".", (c3d.IndexOf(".") + 1)));
            hj.Close();
            c3d = "AeccXUi" + module + ".Aecc" + (module == "Land" ? "" : module) + "Application." + c3d;
            dynamic acadApp = Application.AcadApplication;
            dynamic aeccApp = acadApp.GetInterfaceObject(c3d);
            return aeccApp;
        }
&lt;/LI-CODE&gt;</description>
      <pubDate>Sat, 18 Dec 2021 14:49:45 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/civil-3d-customization-forum/convert-code-from-lisp-to-c-sharp/m-p/10830945#M5979</guid>
      <dc:creator>Jeff_M</dc:creator>
      <dc:date>2021-12-18T14:49:45Z</dc:date>
    </item>
    <item>
      <title>Re: convert   code From  Lisp  to  C-Sharp</title>
      <link>https://forums.autodesk.com/t5/civil-3d-customization-forum/convert-code-from-lisp-to-c-sharp/m-p/10831796#M5980</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/32637"&gt;@Jeff_M&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;EM&gt;&lt;FONT face="arial black,avant garde"&gt;Thanks a lot&lt;/FONT&gt;&lt;/EM&gt;&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Sun, 19 Dec 2021 04:32:27 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/civil-3d-customization-forum/convert-code-from-lisp-to-c-sharp/m-p/10831796#M5980</guid>
      <dc:creator>hosneyalaa</dc:creator>
      <dc:date>2021-12-19T04:32:27Z</dc:date>
    </item>
  </channel>
</rss>

