<?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: Extract an element from rawdescription in Civil 3D Customization Forum</title>
    <link>https://forums.autodesk.com/t5/civil-3d-customization-forum/extract-an-element-from-rawdescription/m-p/11986066#M3610</link>
    <description>&lt;P&gt;Thank you,&lt;/P&gt;&lt;P&gt;that's just what I needed. worked as needed. now to decipher.&lt;/P&gt;</description>
    <pubDate>Wed, 24 May 2023 14:17:16 GMT</pubDate>
    <dc:creator>johnd</dc:creator>
    <dc:date>2023-05-24T14:17:16Z</dc:date>
    <item>
      <title>Extract an element from rawdescription</title>
      <link>https://forums.autodesk.com/t5/civil-3d-customization-forum/extract-an-element-from-rawdescription/m-p/11983545#M3605</link>
      <description>&lt;P&gt;This is the rawdescription of my cogo point for the Code PL_EX:&amp;nbsp;&lt;/P&gt;&lt;P&gt;"PL_EX 0 OTHER NATURAL_GAS VIVAX 7 0 STEEL_ENLINK (8254/15)"&lt;/P&gt;&lt;P&gt;I want to extract the "7" and the&amp;nbsp; "0" from the description separately.&lt;/P&gt;&lt;P&gt;What is the simplest way to do this?&lt;/P&gt;&lt;P&gt;The two values would always be in the same order but not at the same position since other elements before it may be longer or shorter.&lt;/P&gt;</description>
      <pubDate>Tue, 23 May 2023 18:06:32 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/civil-3d-customization-forum/extract-an-element-from-rawdescription/m-p/11983545#M3605</guid>
      <dc:creator>johnd</dc:creator>
      <dc:date>2023-05-23T18:06:32Z</dc:date>
    </item>
    <item>
      <title>Re: Extract an element from rawdescription</title>
      <link>https://forums.autodesk.com/t5/civil-3d-customization-forum/extract-an-element-from-rawdescription/m-p/11983829#M3606</link>
      <description>&lt;P&gt;Hi John,&lt;BR /&gt;Instead of COGO points I'd create a shapefile and use feature styling. The big plus would be the ability to query only those points with 7 or 0.&lt;BR /&gt;Dave&lt;/P&gt;</description>
      <pubDate>Tue, 23 May 2023 20:10:33 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/civil-3d-customization-forum/extract-an-element-from-rawdescription/m-p/11983829#M3606</guid>
      <dc:creator>Pointdump</dc:creator>
      <dc:date>2023-05-23T20:10:33Z</dc:date>
    </item>
    <item>
      <title>Re: Extract an element from rawdescription</title>
      <link>https://forums.autodesk.com/t5/civil-3d-customization-forum/extract-an-element-from-rawdescription/m-p/11985468#M3607</link>
      <description>&lt;P&gt;Thanks for the suggestion. However, this is going into an existing lisp routine that will modify the elevation of the point using those two varying numbers. The first (7) is a depth of cover from Grade and the second (0) is water depth if applicable. I will use these two values to calculate a new elevation in the point and use that value elsewhere in the routine.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 24 May 2023 11:42:32 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/civil-3d-customization-forum/extract-an-element-from-rawdescription/m-p/11985468#M3607</guid>
      <dc:creator>johnd</dc:creator>
      <dc:date>2023-05-24T11:42:32Z</dc:date>
    </item>
    <item>
      <title>Re: Extract an element from rawdescription</title>
      <link>https://forums.autodesk.com/t5/civil-3d-customization-forum/extract-an-element-from-rawdescription/m-p/11985862#M3608</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/2936266"&gt;@johnd&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Can your routine call up a point group? If you can, then put the 7's and 0's in their own own individual group. Then call up the PG, not the description.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 24 May 2023 13:25:47 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/civil-3d-customization-forum/extract-an-element-from-rawdescription/m-p/11985862#M3608</guid>
      <dc:creator>ChicagoLooper</dc:creator>
      <dc:date>2023-05-24T13:25:47Z</dc:date>
    </item>
    <item>
      <title>Re: Extract an element from rawdescription</title>
      <link>https://forums.autodesk.com/t5/civil-3d-customization-forum/extract-an-element-from-rawdescription/m-p/11985942#M3609</link>
      <description>&lt;P&gt;Split the rawdescription by the spaces, then use the 5th &amp;amp; 6th elements in the list:&lt;/P&gt;
&lt;LI-CODE lang="lisp"&gt;;;;str2list by John Uhden, as posted to the adesk customization newsgroup
(defun Str2List (str pat / i j n lst)
  (cond
    ((/= (type str)(type pat) 'STR))
    ((= str pat)'(""))
    (T
      (setq i 0 n (strlen pat))
      (while (setq j (vl-string-search pat str i))
        (setq lst (cons (substr str (1+ i)(- j i)) lst)
              i (+ j n)
        )
      )
      (reverse (cons (substr str (1+ i)) lst))
    )
  )
)
&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Command: (setq str "PL_EX 0 OTHER NATURAL_GAS VIVAX 7 0 STEEL_ENLINK (8254/15)")&lt;BR /&gt;"PL_EX 0 OTHER NATURAL_GAS VIVAX 7 0 STEEL_ENLINK (8254/15)"&lt;/P&gt;
&lt;P&gt;Command: (setq thelist (str2list str " "))&lt;BR /&gt;("PL_EX" "0" "OTHER" "NATURAL_GAS" "VIVAX" "7" "0" "STEEL_ENLINK" "(8254/15)")&lt;/P&gt;
&lt;P&gt;Command: (nth 5 thelist)&lt;BR /&gt;"7"&lt;/P&gt;
&lt;P&gt;Command: (nth 6 thelist)&lt;BR /&gt;"0"&lt;/P&gt;</description>
      <pubDate>Wed, 24 May 2023 13:46:11 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/civil-3d-customization-forum/extract-an-element-from-rawdescription/m-p/11985942#M3609</guid>
      <dc:creator>Jeff_M</dc:creator>
      <dc:date>2023-05-24T13:46:11Z</dc:date>
    </item>
    <item>
      <title>Re: Extract an element from rawdescription</title>
      <link>https://forums.autodesk.com/t5/civil-3d-customization-forum/extract-an-element-from-rawdescription/m-p/11986066#M3610</link>
      <description>&lt;P&gt;Thank you,&lt;/P&gt;&lt;P&gt;that's just what I needed. worked as needed. now to decipher.&lt;/P&gt;</description>
      <pubDate>Wed, 24 May 2023 14:17:16 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/civil-3d-customization-forum/extract-an-element-from-rawdescription/m-p/11986066#M3610</guid>
      <dc:creator>johnd</dc:creator>
      <dc:date>2023-05-24T14:17:16Z</dc:date>
    </item>
  </channel>
</rss>

