<?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: Attribute value from text .dat in Visual LISP, AutoLISP and General Customization Forum</title>
    <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6317467#M132392</link>
    <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;@Anonymous wrote:&lt;BR /&gt;
&lt;P&gt;Henrique,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Sorry my explaination wasn't too clear.&lt;/P&gt;
&lt;P&gt;What I mean earlier was in the .dat, the same brand can have few codes. Eg. Storage have three codes, 1122,1133,1144.&lt;/P&gt;
&lt;P&gt;In the dialog box during insertion, I wish to know which Storage I am choosing if I select one before placing, ie. if the code can be visible (but not selectable) in the dialog.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;.dat&lt;/P&gt;
&lt;P&gt;1122,STORAGE&lt;/P&gt;
&lt;P&gt;1133,STORAGE&lt;/P&gt;
&lt;P&gt;1144,STORAGE&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks&lt;/P&gt;
&lt;P&gt;mcmk8&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Hi mcmk8,&lt;/P&gt;
&lt;P&gt;I'm with a very large workload, if I have some free time, I'll see what I can do...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Henrique&lt;/P&gt;</description>
    <pubDate>Tue, 10 May 2016 09:30:19 GMT</pubDate>
    <dc:creator>hmsilva</dc:creator>
    <dc:date>2016-05-10T09:30:19Z</dc:date>
    <item>
      <title>Attribute value from text .dat</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6309510#M132382</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm a novice on lisp and especially DCL.&lt;/P&gt;&lt;P&gt;Please help me out in this lisp with DCL to insert an attribute block in my dialog where I can select the Brand &amp;amp; Code values from the drop down popup-list. This is to enhance my attribute entry to every insertion of this block. There are about 150 values for both Brand and Code that I need on every drawing. Attached are the DCL, Lisp, block and the .DAT. I hope the values can be taken from the .DAT.&lt;/P&gt;&lt;P&gt;I had posted this at CADTutor.net but did not get much response. Thanks for the guy help anyway.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What I hope to acheive:&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;insert block with my dcl that I can select the Brand &amp;amp; Code.&lt;/LI&gt;&lt;LI&gt;values for Code and Brand are from .dat.&lt;/LI&gt;&lt;LI&gt;if possible, if I select a code, it automatically filled brand base on the .dat and vice versa. I hope I not asking too much here.&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;Thanks..&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;DCL:&lt;/P&gt;&lt;PRE&gt;br : dialog { label = "Enhanced Attribute Input"; width = 42;
		: popup_list { label = "Code  "; key = "sel-code"; value = 3; allow_accept = true; }
		: popup_list { label = "Brand"; key = "sel-brand"; value = 3; allow_accept = true; }
		: spacer { width = 1; }
		ok_cancel;
		}&lt;/PRE&gt;&lt;P&gt;Lisp:&lt;/P&gt;&lt;PRE&gt;(defun C:BRAND (/ names dcl_id lst cd br it bk pt)
  (setq names '("1000 - COUNTRY ROAD WOMENS" "1011 - SPORTCRAFT"
                "1022 - DAVID LAWRENCE" "2100 - FRAGRANCE TRI"
                "2117 - FRAGRANCE L'OR" "2133 - BURBERRY BEAUTY"
                )
        )
  (if (and (&amp;lt; 0 (setq dcl_id (load_dialog "brand.dcl")))
           (new_dialog "br" dcl_id)
           )
    (progn
      (setq lst (mapcar '(lambda (x) (cons (substr x 1 4) (substr x 8)))
                        names
                        )
            cd  (mapcar 'car lst)
            br  (mapcar 'cdr lst)
            )
      (mapcar '(lambda (k v)
                 (start_list k)
                 (mapcar 'add_list v)
                 (end_list)
                 )
              '("sel-code" "sel-brand")
              (list cd br)
              )
      (action_tile "cancel" "(done_dialog)")
      (action_tile
        "accept"
        "(setq it (mapcar 'atoi (list (get_tile \"sel-code\") (get_tile \"sel-brand\")))) (done_dialog)"
        )
      (start_dialog)
      (unload_dialog dcl_id)
      (if
        (and
          (apply 'and it)
          (setq pt (getpoint "\nPick Attribute insertion point: "))
          (if (not (or (tblsearch "BLOCK" (setq bk "AREA_ATTRIB_M"))
                       (setq bk (findfile "H:/AREA_ATTRIB_M.dwg"))
                       )
                   )
            (progn
              (princ
                "\nBlock not found drawing and either in H:DCL Test folder !"
                )
              nil
              )
            t
            )
          )
         (command "_.-insert"
                  bk
                  "_non"
                  pt
                  "1"
                  "1"
                  "0."
                  (nth (car it) cd)
                  (nth (cadr it) br)
                  ""
                  ""
                  )
         )
      )
    )
  (princ)
  )&lt;/PRE&gt;&lt;P&gt;Data:&lt;/P&gt;&lt;PRE&gt;**CODE &amp;amp; BRANDS
**CODE, BRANDS
**----------------
*1006-COUNTRY ROAD WOMENS
1006,COUNTRY ROAD WOMENS
*1014-SPORTCRAFT
1014,SPORTCRAFT
*1022-DAVID LAWRENCE
1022,DAVID LAWRENCE
*2379-OPI
2379,OPI
*2565-MAC
2565,MAC
*3498-BLAZER
3498,BLAZER
*4753-QUICKSILVER
4753,QUICKSILVER&lt;/PRE&gt;</description>
      <pubDate>Thu, 05 May 2016 04:50:41 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6309510#M132382</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-05-05T04:50:41Z</dc:date>
    </item>
    <item>
      <title>Re: Attribute value from text .dat</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6310325#M132383</link>
      <description>&lt;P&gt;&lt;FONT face="georgia,palatino" size="3"&gt;The guy who helped you out by writing the lisp codes has a name I think.&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 05 May 2016 15:38:18 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6310325#M132383</guid>
      <dc:creator>_Tharwat</dc:creator>
      <dc:date>2016-05-05T15:38:18Z</dc:date>
    </item>
    <item>
      <title>Re: Attribute value from text .dat</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6311381#M132384</link>
      <description>&lt;P&gt;Hi Tharwat,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Sorry I left out your name. Thanks for all your help.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It would be much appreciated if you could please continue to help me to fix my Lisp.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks again..&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 06 May 2016 04:20:44 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6311381#M132384</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-05-06T04:20:44Z</dc:date>
    </item>
    <item>
      <title>Re: Attribute value from text .dat</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6313515#M132385</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;@Anonymous wrote:&lt;BR /&gt;
&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I'm a novice on lisp and especially DCL.&lt;/P&gt;
&lt;P&gt;Please help me out in this lisp with DCL to insert an attribute block in my dialog where I can select the Brand &amp;amp; Code values from the drop down popup-list. This is to enhance my attribute entry to every insertion of this block. There are about 150 values for both Brand and Code that I need on every drawing. Attached are the DCL, Lisp, block and the .DAT. I hope the values can be taken from the .DAT.&lt;/P&gt;
&lt;P&gt;I had posted this at CADTutor.net but did not get much response. Thanks for the guy help anyway.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;What I hope to acheive:&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;insert block with my dcl that I can select the Brand &amp;amp; Code.&lt;/LI&gt;
&lt;LI&gt;values for Code and Brand are from .dat.&lt;/LI&gt;
&lt;LI&gt;if possible, if I select a code, it automatically filled brand base on the .dat and vice versa. I hope I not asking too much here.&lt;/LI&gt;
&lt;/OL&gt;
&lt;P&gt;....&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/660967"&gt;@_Tharwat&lt;/a&gt;&lt;/P&gt;
&lt;P&gt;I hope you do not mind, my friend!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;@Anonymous,&lt;/P&gt;
&lt;P&gt;It is a good principle to link mew messages to the previous ones...&lt;/P&gt;
&lt;P&gt;&lt;A href="http://www.cadtutor.net/forum/showthread.php?96603-Attribute-dcl-popup-list&amp;amp;highlight=names+dcl_id+lst+pt%29" target="_blank"&gt;http://www.cadtutor.net/forum/showthread.php?96603-Attribute-dcl-popup-list&amp;amp;highlight=names+dcl_id+lst+pt%29&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;To me, it does not make sense to have two 'popup_list' one for 'CODES' and another for 'BRANDS', since a CODE will only corresponds one BRAND, and vice versa.&lt;BR /&gt;My suggestion is to use only one 'popup_list' and use the 'CODES' and 'BRANDS'...&lt;/P&gt;
&lt;P&gt;i.e.&lt;BR /&gt;1006,COUNTRY ROAD WOMENS&lt;BR /&gt;1014,SPORTCRAFT&lt;BR /&gt;1022,DAVID LAWRENCE&lt;BR /&gt;2379,OPI&lt;BR /&gt;2565,MAC&lt;BR /&gt;3498,BLAZER&lt;BR /&gt;4753,QUICKSILVER&lt;BR /&gt;...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Said that, what I 'quick and dirty' did from the code revised by Tharwat, was:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Change the DCL file to have just one 'popup_list', the 'BRANDS'&lt;BR /&gt;Change the LSP file to read the 'brand.dat' file and create the names list from it&lt;BR /&gt;Call the revised DCL to get the 'BRAND'&lt;BR /&gt;Insert the 'AREA_ATTRIB_M.dwg' without modifying the attributes strings&lt;BR /&gt;Change the attributes strings with the return from DCL&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Please keep in mind that those codes attached by me, are just a starting point and untested...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hope this helps, &lt;BR /&gt;Henrique&lt;/P&gt;</description>
      <pubDate>Sat, 07 May 2016 16:02:18 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6313515#M132385</guid>
      <dc:creator>hmsilva</dc:creator>
      <dc:date>2016-05-07T16:02:18Z</dc:date>
    </item>
    <item>
      <title>Re: Attribute value from text .dat</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6314152#M132386</link>
      <description>&lt;P&gt;Henrique,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;That was excelent... ! &amp;nbsp;Thanks so much...&lt;/P&gt;&lt;P&gt;Just minor thing which can be ignore. The Cancel still try to insert the block but an Esc easily terminate.&lt;/P&gt;&lt;P&gt;One thing just thought of, if its possible to display the Code in the dialog box. Reason is sometime a Brand can have multiple Codes. I know it sound strange. With the code display one can determine which brand to choose.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I like to thank you again for your great effort.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Cheers&lt;/P&gt;&lt;P&gt;mcmk8&lt;/P&gt;</description>
      <pubDate>Sun, 08 May 2016 14:20:10 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6314152#M132386</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-05-08T14:20:10Z</dc:date>
    </item>
    <item>
      <title>Re: Attribute value from text .dat</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6314158#M132387</link>
      <description>&lt;P&gt;Almost missed this. Is there a possbility that if I changed a code in data .dat file, it can sync and update the particular code in the drawing.&lt;/P&gt;&lt;P&gt;It's ok if not possible, but it will be very good if possible.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks again.&lt;/P&gt;&lt;P&gt;mcmk8&lt;/P&gt;</description>
      <pubDate>Sun, 08 May 2016 14:26:28 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6314158#M132387</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-05-08T14:26:28Z</dc:date>
    </item>
    <item>
      <title>Re: Attribute value from text .dat</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6314256#M132388</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/75977"&gt;@hmsilva&lt;/a&gt; wrote:&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/660967"&gt;@_Tharwat&lt;/a&gt;&lt;/P&gt;
&lt;P&gt;I hope you do not mind, my friend!&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Henrique&lt;/P&gt;
&lt;HR /&gt;
&lt;P&gt;&lt;FONT face="georgia,palatino" size="3"&gt;Hi &lt;SPAN&gt;Henrique,&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="georgia,palatino" size="3"&gt;You know I don't mind at all.&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="georgia,palatino" size="3"&gt;Here is the thread for the same OP that I tried to help him but it seems that&amp;nbsp;he is&amp;nbsp;singing in a place far away from&amp;nbsp;my questions so I decided to stay a side&amp;nbsp;&lt;img id="smileyhappy" class="emoticon emoticon-smileyhappy" src="https://forums.autodesk.com/i/smilies/16x16_smiley-happy.png" alt="Smiley Happy" title="Smiley Happy" /&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://www.cadtutor.net/forum/showthread.php?96603-Attribute-dcl-popup-list&amp;amp;p=660115&amp;amp;viewfull=1#post660115" target="_blank"&gt;THIS THREAD&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Sun, 08 May 2016 17:07:38 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6314256#M132388</guid>
      <dc:creator>_Tharwat</dc:creator>
      <dc:date>2016-05-08T17:07:38Z</dc:date>
    </item>
    <item>
      <title>Re: Attribute value from text .dat</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6314465#M132389</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/660967"&gt;@_Tharwat&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/75977"&gt;@hmsilva&lt;/a&gt; wrote:&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/660967"&gt;@_Tharwat&lt;/a&gt;&lt;/P&gt;
&lt;P&gt;I hope you do not mind, my friend!&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Henrique&lt;/P&gt;
&lt;HR /&gt;
&lt;P&gt;&lt;FONT face="georgia,palatino" size="3"&gt;Hi &lt;SPAN&gt;Henrique,&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="georgia,palatino" size="3"&gt;You know I don't mind at all.&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="georgia,palatino" size="3"&gt;Here is the thread for the same OP that I tried to help him but it seems that&amp;nbsp;he is&amp;nbsp;singing in a place far away from&amp;nbsp;my questions so I decided to stay a side&amp;nbsp;&lt;img id="smileyhappy" class="emoticon emoticon-smileyhappy" src="https://forums.autodesk.com/i/smilies/16x16_smiley-happy.png" alt="Smiley Happy" title="Smiley Happy" /&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://www.cadtutor.net/forum/showthread.php?96603-Attribute-dcl-popup-list&amp;amp;p=660115&amp;amp;viewfull=1#post660115" target="_blank"&gt;THIS THREAD&lt;/A&gt;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Hi Tharwat,&lt;/P&gt;
&lt;P&gt;I understand that.&lt;BR /&gt;I did read that thread, I even put a link in my previous message... &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Cheers&lt;BR /&gt;Henrique&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 08 May 2016 22:10:17 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6314465#M132389</guid>
      <dc:creator>hmsilva</dc:creator>
      <dc:date>2016-05-08T22:10:17Z</dc:date>
    </item>
    <item>
      <title>Re: Attribute value from text .dat</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6314470#M132390</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;@Anonymous wrote:&lt;BR /&gt;
&lt;P&gt;Henrique,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;That was excelent... ! &amp;nbsp;Thanks so much...&lt;/P&gt;
&lt;P&gt;Just minor thing which can be ignore. The Cancel still try to insert the block but an Esc easily terminate.&lt;/P&gt;
&lt;P&gt;One thing just thought of, if its possible to display the Code in the dialog box. Reason is sometime a Brand can have multiple Codes. I know it sound strange. With the code display one can determine which brand to choose.&lt;/P&gt;
&lt;P&gt;...&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;You're welcome, mcmk8,&lt;/P&gt;
&lt;P&gt;attached, revised code to call the original 'brand.dcl' file.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;@Anonymous wrote:&lt;BR /&gt;
&lt;P&gt;Almost missed this. Is there a possbility that if I changed a code in data .dat file, it can sync and update the particular code in the drawing.&lt;/P&gt;
&lt;P&gt;...&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;mcmk8,&lt;/P&gt;
&lt;P&gt;if to a 'CODE' would correspond only&amp;nbsp;one 'BRAND' it would be easy to read the .dat file, and change the CODE values if they were different in a specific BRAND, but you have said:&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;&lt;EM&gt;'sometime a Brand can have multiple Codes'&lt;/EM&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;so, it should not be possible ...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hope this helps, &lt;BR /&gt;Henrique&lt;/P&gt;</description>
      <pubDate>Sun, 08 May 2016 22:24:59 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6314470#M132390</guid>
      <dc:creator>hmsilva</dc:creator>
      <dc:date>2016-05-08T22:24:59Z</dc:date>
    </item>
    <item>
      <title>Re: Attribute value from text .dat</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6317080#M132391</link>
      <description>&lt;P&gt;Henrique,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Sorry my explaination wasn't too clear.&lt;/P&gt;&lt;P&gt;What I mean earlier was in the .dat, the same brand can have few codes. Eg. Storage have three codes, 1122,1133,1144.&lt;/P&gt;&lt;P&gt;In the dialog box during insertion, I wish to know which Storage I am choosing if I select one before placing, ie. if the code can be visible (but not selectable) in the dialog.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;.dat&lt;/P&gt;&lt;P&gt;1122,STORAGE&lt;/P&gt;&lt;P&gt;1133,STORAGE&lt;/P&gt;&lt;P&gt;1144,STORAGE&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;mcmk8&lt;/P&gt;</description>
      <pubDate>Tue, 10 May 2016 04:06:51 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6317080#M132391</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-05-10T04:06:51Z</dc:date>
    </item>
    <item>
      <title>Re: Attribute value from text .dat</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6317467#M132392</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;@Anonymous wrote:&lt;BR /&gt;
&lt;P&gt;Henrique,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Sorry my explaination wasn't too clear.&lt;/P&gt;
&lt;P&gt;What I mean earlier was in the .dat, the same brand can have few codes. Eg. Storage have three codes, 1122,1133,1144.&lt;/P&gt;
&lt;P&gt;In the dialog box during insertion, I wish to know which Storage I am choosing if I select one before placing, ie. if the code can be visible (but not selectable) in the dialog.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;.dat&lt;/P&gt;
&lt;P&gt;1122,STORAGE&lt;/P&gt;
&lt;P&gt;1133,STORAGE&lt;/P&gt;
&lt;P&gt;1144,STORAGE&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks&lt;/P&gt;
&lt;P&gt;mcmk8&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Hi mcmk8,&lt;/P&gt;
&lt;P&gt;I'm with a very large workload, if I have some free time, I'll see what I can do...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Henrique&lt;/P&gt;</description>
      <pubDate>Tue, 10 May 2016 09:30:19 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6317467#M132392</guid>
      <dc:creator>hmsilva</dc:creator>
      <dc:date>2016-05-10T09:30:19Z</dc:date>
    </item>
    <item>
      <title>Re: Attribute value from text .dat</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6317529#M132393</link>
      <description>&lt;P&gt;Revised code...&lt;/P&gt;
&lt;P&gt;It will load 'brand_h.dcl'.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hope this helps, &lt;BR /&gt;Henrique&lt;/P&gt;</description>
      <pubDate>Tue, 10 May 2016 10:30:01 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6317529#M132393</guid>
      <dc:creator>hmsilva</dc:creator>
      <dc:date>2016-05-10T10:30:01Z</dc:date>
    </item>
    <item>
      <title>Re: Attribute value from text .dat</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6437619#M132394</link>
      <description>&lt;P&gt;I am coming back to this to see if the selection from the drop down list can be improve by adding a new Group in the .dat&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The new brand.dat would be as below, Group,Code,Brand:&lt;/P&gt;&lt;P&gt;&lt;U&gt;brand.dat&lt;/U&gt;&lt;/P&gt;&lt;P&gt;Womens,1242,Virgo&lt;/P&gt;&lt;P&gt;Womens,1268,Sara&lt;/P&gt;&lt;P&gt;......&lt;/P&gt;&lt;P&gt;Kids,4711,Hux Baby&lt;/P&gt;&lt;P&gt;Kids,4606,Gant&lt;/P&gt;&lt;P&gt;......&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;With the introduction of Group, we hope this will be a filter to the Brand list. Since the brand.dat numbers are growing from 150 to 200, we hope the dropdown list will be shorten with the new Group field.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Attached is a small version of my .dat for testing. I hope the new dialog I can choose Group then Brand (Group filtered) before inserting the attribute block.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;mcmk8&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 15 Jul 2016 07:33:41 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6437619#M132394</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-07-15T07:33:41Z</dc:date>
    </item>
    <item>
      <title>Re: Attribute value from text .dat</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6464537#M132395</link>
      <description>Hi _Tharwat, Thank you for posting the code. We had been trying for a day or so to write a similar routine / dialog box that utilised ini files for layers, block names and popup list values for attributes. We had been kind of struggling until one of my colleagues found this thread where your code is really nicely structured and simple to follow. By using some of this code and a few of Lee Mac's routines we have managed to create what we were trying to achieve. To give credit where credit is due I would like to acknowledge you in our lisp file and documentation. Would that be ok? If you have any preference for the wording please feel free to send me a PM Cheers Paul</description>
      <pubDate>Thu, 28 Jul 2016 12:52:42 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6464537#M132395</guid>
      <dc:creator>FrisoKramer</dc:creator>
      <dc:date>2016-07-28T12:52:42Z</dc:date>
    </item>
    <item>
      <title>Re: Attribute value from text .dat</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6464569#M132396</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/490649"&gt;@FrisoKramer&lt;/a&gt; wrote:&lt;BR /&gt;Hi _Tharwat, Thank you for posting the code. We had been trying for a day or so to write a similar routine / dialog box that utilised ini files for layers, block names and popup list values for attributes. We had been kind of struggling until one of my colleagues found this thread where your code is really nicely structured and simple to follow. By using some of this code and a few of Lee Mac's routines we have managed to create what we were trying to achieve. To give credit where credit is due I would like to acknowledge you in our lisp file and documentation. Would that be ok? If you have any preference for the wording please feel free to send me a PM Cheers Paul&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Many thanks for your kind words Paul, highly appreciated.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I don't have any reference but I would love to be of any assistance if you are in need of any help in this regard.&lt;/P&gt;
&lt;P&gt;I would love to know what you have so far with that lisp file and documentation if that possible so you can PM me if that is okay with you.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best regards&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Tharwat&lt;/P&gt;</description>
      <pubDate>Thu, 28 Jul 2016 13:06:17 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6464569#M132396</guid>
      <dc:creator>_Tharwat</dc:creator>
      <dc:date>2016-07-28T13:06:17Z</dc:date>
    </item>
    <item>
      <title>Re: Attribute value from text .dat</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6464644#M132397</link>
      <description>Thank You, that sounds great. I'll send you a PM shortly. We are implementing a CAD standard for work as executed drawings that is compatible with Open Spatial's system for validating drawings, and planning to have the new files and menus ready by the end of next week. We needed to make it easier for the consultants to use since there are some 150 standard blocks that need to go on the right layers and very specific attribute data. The end result is coming along pretty awesome. What makes it so unusual is that after getting the first routine and dialog box to work. I got one of my staff to write SQL to generate three main ini files, 150 lisp routines and 150 DCL files in a matter of seconds from our oracle database. We did it this way to make it easier to have it all in sync and maintain as well as use for other standards. We have also added smarts into the menus / routines to manage the layers incredibly well. We are also partly through generating help files the same way. Those also have "dialog boxes" (forms) in them with popup lists and copy buttons so LT users can use the help files to get the correct attributes.. I am sure that after it gets implemented the consultants will ask for more functionality once they see how much time it is saving them. The ini files work well for configuring layers, block names, attributes and pick lists. Lee Mac's routines mean the lisp files do not need to constantly open and read the data because it can be stored in lists. I certainly cannot wait to get it finished.</description>
      <pubDate>Thu, 28 Jul 2016 13:37:30 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/attribute-value-from-text-dat/m-p/6464644#M132397</guid>
      <dc:creator>FrisoKramer</dc:creator>
      <dc:date>2016-07-28T13:37:30Z</dc:date>
    </item>
  </channel>
</rss>

