<?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: Room Area Calculate in Visual LISP, AutoLISP and General Customization Forum</title>
    <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513957#M57456</link>
    <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/69526"&gt;@Kent1Cooper&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can we only proceed from P1 and P2?&lt;/P&gt;</description>
    <pubDate>Mon, 02 Aug 2021 12:39:52 GMT</pubDate>
    <dc:creator>k005</dc:creator>
    <dc:date>2021-08-02T12:39:52Z</dc:date>
    <item>
      <title>Room Area Calculate</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513272#M57446</link>
      <description>&lt;P&gt;Hello friends&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;How can I print the actual area of the room in the middle of these two points by selecting the points P1 and P2?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;unit : cm&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;room area : m²..&lt;/P&gt;</description>
      <pubDate>Mon, 02 Aug 2021 06:42:46 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513272#M57446</guid>
      <dc:creator>k005</dc:creator>
      <dc:date>2021-08-02T06:42:46Z</dc:date>
    </item>
    <item>
      <title>Re: Room Area Calculate</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513323#M57447</link>
      <description>&lt;P&gt;Try this.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;(defun c:rarea ( / *error* p1 p2 dx dy str)
	(defun *error* ( msg )
		(if (not (member msg '("Function cancelled" "quit / exit abort")))
			(princ)
		)
	)
	(while 
		(and
			(setq p1 (getpoint "\nFirst point &amp;gt;"))
			(setq p2 (getpoint "\nSecond point &amp;gt;"))
		)
		(setq dx (apply '- (vl-sort (mapcar 'car (list p1 p2)) '&amp;gt;)))
		(setq dy (apply '- (vl-sort (mapcar 'cadr (list p1 p2)) '&amp;gt;)))
		(setq str (rtos (* dx dy 0.0001) 2 2))
		(cond 
			((not (vl-string-position (ascii ".") str))
				(setq str (strcat str ".00"))
			)
			((= (-(strlen str)(vl-string-position (ascii ".") str)) 2)
				(setq str (strcat str "0"))
			)
		)
		(entmakex
			(list
				'(0 . "TEXT")
				(cons 10 (mapcar '* (mapcar '+ p1 p2) (list 0.5 0.5)))
				(cons 50 0)
				(cons 1 (strcat str " m\U+00B2"))
			)
		)
		
	)
	(princ)
)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 02 Aug 2021 07:18:42 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513323#M57447</guid>
      <dc:creator>hak_vz</dc:creator>
      <dc:date>2021-08-02T07:18:42Z</dc:date>
    </item>
    <item>
      <title>Re: Room Area Calculate</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513332#M57448</link>
      <description>&lt;P&gt;This is an excellent Learn lisp. 1st area=(x1-x2)*(y1-y2), mid point can be calculated as (x1 +x2)/2 (y1+y2)/2&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So start with (setq pt1 (getpoint "\nmessage "))&lt;/P&gt;&lt;P&gt;then look at what (car pt1) &amp;amp; (cadr pt1 ) reveal&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The only way to learn is have a go.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 02 Aug 2021 07:22:17 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513332#M57448</guid>
      <dc:creator>Sea-Haven</dc:creator>
      <dc:date>2021-08-02T07:22:17Z</dc:date>
    </item>
    <item>
      <title>Re: Room Area Calculate</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513609#M57449</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/5530556"&gt;@hak_vz&lt;/a&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;I don't understand the usage?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm just trying to reach the Real Field from point P1 and P2.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Your code runs in a continuous loop. Or I couldn't.&lt;/P&gt;</description>
      <pubDate>Mon, 02 Aug 2021 09:58:02 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513609#M57449</guid>
      <dc:creator>k005</dc:creator>
      <dc:date>2021-08-02T09:58:02Z</dc:date>
    </item>
    <item>
      <title>Re: Room Area Calculate</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513661#M57450</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/537692"&gt;@k005&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/5530556"&gt;@hak_vz&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I don't understand the usage?&lt;/P&gt;&lt;P&gt;I'm just trying to reach the Real Field from point P1 and P2.&lt;/P&gt;&lt;P&gt;Your code runs in a continuous loop. Or I couldn't.&lt;/P&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;Code works in continuous loop. Pick two points along room diagonal and it creates area text at middle point of this two points. Y&lt;/P&gt;</description>
      <pubDate>Mon, 02 Aug 2021 10:25:51 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513661#M57450</guid>
      <dc:creator>hak_vz</dc:creator>
      <dc:date>2021-08-02T10:25:51Z</dc:date>
    </item>
    <item>
      <title>Re: Room Area Calculate</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513685#M57451</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/537692"&gt;@k005&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Kent1Cooper_0-1627900385656.png" style="width: 400px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/947528i0CFD39A02A8B99BA/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Kent1Cooper_0-1627900385656.png" alt="Kent1Cooper_0-1627900385656.png" /&gt;&lt;/span&gt;&lt;SPAN style="font-family: inherit;"&gt;.&lt;/SPAN&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;So it appears you want the clouded upper-right corner bump-out deducted from the plain-rectangle area [which gives 4.6875 m², as compared to the full-rectangle a x b = 4.7025 m²].&amp;nbsp; That is not going to be possible if what you want is to pick P1 and P2 only.&amp;nbsp; You will need something more, such as to use the AREA command and have a routine take the result and put it into Text, or to have a door-opening header Line, turn off the doors' Layer, and use BOUNDARY or BPOLY to make a Polyline that's the actual shape of the room, and use its area.&lt;/P&gt;</description>
      <pubDate>Mon, 02 Aug 2021 10:41:36 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513685#M57451</guid>
      <dc:creator>Kent1Cooper</dc:creator>
      <dc:date>2021-08-02T10:41:36Z</dc:date>
    </item>
    <item>
      <title>Re: Room Area Calculate</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513721#M57452</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/537692"&gt;@k005&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Here is another version that asks to select text to modify&lt;/P&gt;&lt;LI-CODE lang="general"&gt;(defun c:rarea ( / *error* p1 p2 dx dy str)
	(defun *error* ( msg )
		(if (not (member msg '("Function cancelled" "quit / exit abort")))
			(princ)
		)
	)
	(while 
		(and
			(setq p1 (getpoint "\nFirst point &amp;gt;"))
			(setq p2 (getpoint "\nSecond point &amp;gt;"))
			(setq e (car (entsel "\nSelect text to assign area &amp;gt;")))
		)
		(setq dx (apply '- (vl-sort (mapcar 'car (list p1 p2)) '&amp;gt;)))
		(setq dy (apply '- (vl-sort (mapcar 'cadr (list p1 p2)) '&amp;gt;)))
		(setq str (rtos (* dx dy 0.0001) 2 2))
		(cond 
			((not (vl-string-position (ascii ".") str))
				(setq str (strcat str ".00"))
			)
			((= (-(strlen str)(vl-string-position (ascii ".") str)) 2)
				(setq str (strcat str "0"))
			)
		)
		
		(setq ent (entget e))
		(setq ent(subst (cons 1 (strcat str " m\U+00B2")) (assoc 1 ent) ent))
		(entmod ent)
	)
	(princ)
)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Also, read &lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/69526"&gt;@Kent1Cooper&lt;/a&gt; post for non rectangular areas. In that case you have to create a polyline along inner edge of the room and take its area. Search older posts to this forum and you'll probably find code that works in that way and avoids doors and other obstacles.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 02 Aug 2021 11:04:17 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513721#M57452</guid>
      <dc:creator>hak_vz</dc:creator>
      <dc:date>2021-08-02T11:04:17Z</dc:date>
    </item>
    <item>
      <title>Re: Room Area Calculate</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513918#M57453</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/69526"&gt;@Kent1Cooper&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Yes . I want that part dropped.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;* Now in this example that area is small... but not always this area is small.&lt;/P&gt;</description>
      <pubDate>Mon, 02 Aug 2021 12:26:53 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513918#M57453</guid>
      <dc:creator>k005</dc:creator>
      <dc:date>2021-08-02T12:26:53Z</dc:date>
    </item>
    <item>
      <title>Re: Room Area Calculate</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513930#M57454</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/5530556"&gt;@hak_vz&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have tested...&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My friend ;&lt;/P&gt;&lt;P&gt;I guess I couldn't explain the subject fully.. The cloudy part will be deducted. And I said can we do this from two points?&lt;/P&gt;&lt;P&gt;* Except for rectangular or square areas, I will make two calculations...&lt;/P&gt;</description>
      <pubDate>Mon, 02 Aug 2021 12:27:50 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513930#M57454</guid>
      <dc:creator>k005</dc:creator>
      <dc:date>2021-08-02T12:27:50Z</dc:date>
    </item>
    <item>
      <title>Re: Room Area Calculate</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513949#M57455</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/537692"&gt;@k005&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;.... The cloudy part will be deducted. And I said can we do this from two points? ....&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;If you &lt;EM&gt;draw a header line across the door opening, and turn off the Door Layer&lt;/EM&gt;, a routine could then use the point halfway between the two picked points in a BOUNDARY command, and take the area of the resulting Polyline.&lt;/P&gt;</description>
      <pubDate>Mon, 02 Aug 2021 12:36:16 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513949#M57455</guid>
      <dc:creator>Kent1Cooper</dc:creator>
      <dc:date>2021-08-02T12:36:16Z</dc:date>
    </item>
    <item>
      <title>Re: Room Area Calculate</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513957#M57456</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/69526"&gt;@Kent1Cooper&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can we only proceed from P1 and P2?&lt;/P&gt;</description>
      <pubDate>Mon, 02 Aug 2021 12:39:52 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513957#M57456</guid>
      <dc:creator>k005</dc:creator>
      <dc:date>2021-08-02T12:39:52Z</dc:date>
    </item>
    <item>
      <title>Re: Room Area Calculate</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513967#M57457</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/537692"&gt;@k005&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Can we only proceed from P1 and P2?&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;How could a routine possibly know about the cut-out corner from only those points?&lt;/P&gt;</description>
      <pubDate>Mon, 02 Aug 2021 12:44:01 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513967#M57457</guid>
      <dc:creator>Kent1Cooper</dc:creator>
      <dc:date>2021-08-02T12:44:01Z</dc:date>
    </item>
    <item>
      <title>Re: Room Area Calculate</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513981#M57458</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/69526"&gt;@Kent1Cooper&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have a suggestion:&lt;/P&gt;&lt;P&gt;*Area of triangle consisting of P1 and P2 *2 = Unfallen Area.&lt;/P&gt;&lt;P&gt;From this point on, it seemed to me that we could find the point that I did not give another name and calculate it... I am not sure...&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1. Will the space be deducted ( Yes/No)&lt;BR /&gt;2. P1 and P2&lt;BR /&gt;3. Result text in the middle of P1/P2. ( text height : Textsize )&lt;/P&gt;</description>
      <pubDate>Mon, 02 Aug 2021 12:52:34 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10513981#M57458</guid>
      <dc:creator>k005</dc:creator>
      <dc:date>2021-08-02T12:52:34Z</dc:date>
    </item>
    <item>
      <title>Re: Room Area Calculate</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10514008#M57459</link>
      <description>&lt;P&gt;If the room and the cut-out corner are &lt;EM&gt;always orthogonal&lt;/EM&gt;, it might be possible to get a routine to calculate the area and the cut-out reduction with just one additional point:&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Kent1Cooper_0-1627909110656.png" style="width: 400px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/947604iEA2336699DBCA804/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Kent1Cooper_0-1627909110656.png" alt="Kent1Cooper_0-1627909110656.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;But would there ever be further complications, such as more than one cut-out corner?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 02 Aug 2021 12:59:51 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10514008#M57459</guid>
      <dc:creator>Kent1Cooper</dc:creator>
      <dc:date>2021-08-02T12:59:51Z</dc:date>
    </item>
    <item>
      <title>Re: Room Area Calculate</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10514030#M57460</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/69526"&gt;@Kent1Cooper&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/69526"&gt;@Kent1Cooper&lt;/a&gt;&amp;nbsp;But would there ever be further complications, such as more than one cut-out corner?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Yes, maybe. But it's okay. We can go to the conclusion with P1 P2 P3.&lt;/P&gt;</description>
      <pubDate>Mon, 02 Aug 2021 13:09:52 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10514030#M57460</guid>
      <dc:creator>k005</dc:creator>
      <dc:date>2021-08-02T13:09:52Z</dc:date>
    </item>
    <item>
      <title>Re: Room Area Calculate</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10514381#M57461</link>
      <description>&lt;P&gt;Try this version that edits predefined text. You have scenario with selection of three points. In case there is no cut-out select p2 and p3 at same point.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;(defun c:rarea ( / *error* p1 p2 dx dy dxx dyy str)
	(defun *error* ( msg )
		(if (not (member msg '("Function cancelled" "quit / exit abort")))
			(princ)
		)
	)
	(while 
		(and
			(setq p1 (getpoint "\nFirst point &amp;gt;"))
			(setq p2 (getpoint "\nSecond point &amp;gt;"))
			(setq p3 (getpoint "\nThird point &amp;gt;"))
			(setq e (car (entsel "\nSelect text to assign area &amp;gt;")))
		)
		(setq dx (apply '- (vl-sort (mapcar 'car (list p1 p2)) '&amp;gt;)))
		(setq dy (apply '- (vl-sort (mapcar 'cadr (list p1 p2)) '&amp;gt;)))
		(setq dxx (apply '- (vl-sort (mapcar 'car (list p2 p3)) '&amp;gt;)))
		(setq dyy (apply '- (vl-sort (mapcar 'cadr (list p2 p3)) '&amp;gt;)))

		(setq str (rtos (* (-(* dx dy) (* dxx dyy)) 0.0001) 2 2))
		(cond 
			((not (vl-string-position (ascii ".") str))
				(setq str (strcat str ".00"))
			)
			((= (-(strlen str)(vl-string-position (ascii ".") str)) 2)
				(setq str (strcat str "0"))
			)
		)
		
		(setq ent (entget e))
		(setq ent(subst (cons 1 (strcat str " m\U+00B2")) (assoc 1 ent) ent))
		(entmod ent)
	)
	(princ)
)&lt;/LI-CODE&gt;</description>
      <pubDate>Mon, 02 Aug 2021 15:15:13 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10514381#M57461</guid>
      <dc:creator>hak_vz</dc:creator>
      <dc:date>2021-08-02T15:15:13Z</dc:date>
    </item>
    <item>
      <title>Re: Room Area Calculate</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10514409#M57462</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/5530556"&gt;@hak_vz&lt;/a&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;&lt;P&gt;I have tested in the example attached drawing.&lt;/P&gt;&lt;P&gt;but the result is 4.47 m². requested &lt;STRONG&gt;4.69 m²&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 02 Aug 2021 15:24:44 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10514409#M57462</guid>
      <dc:creator>k005</dc:creator>
      <dc:date>2021-08-02T15:24:44Z</dc:date>
    </item>
    <item>
      <title>Re: Room Area Calculate</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10514474#M57463</link>
      <description>&lt;P&gt;I receive 4.69.&amp;nbsp; You should pick points along same diagonal. P1 and p2 are outer ones, and P3 at cut-off. If you pick points as you presented in your sample then result is 4.47. So for correct result take diagonal that passes through cut- off.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="Untitled.png" style="width: 400px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/947673i5583F93CDAD4EEE8/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Untitled.png" alt="Untitled.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 02 Aug 2021 15:50:01 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10514474#M57463</guid>
      <dc:creator>hak_vz</dc:creator>
      <dc:date>2021-08-02T15:50:01Z</dc:date>
    </item>
    <item>
      <title>Re: Room Area Calculate</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10514554#M57464</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/537692"&gt;@k005&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;&lt;SPAN style="font-family: inherit;"&gt;.... We can go to the conclusion with P1 P2 P3.&lt;/SPAN&gt;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="general"&gt;(defun C:ACCT (/ P1 P2 P3 areafull areacorner area); = Area with Corner Cutout Text
  (setvar 'dimzin 0); don't suppress trailing zeroes
  (setq
    P1 (getpoint "\nFirst overall corner: ")
    P2 (getpoint P1 "nOpposite overall corner: ")
    P3 (getpoint "\nCut-out internal corner: ")
    areafull (mapcar 'abs (mapcar '- P2 P1))
    areacorner (mapcar 'min (mapcar 'abs (mapcar '- P3 P1)) (mapcar 'abs (mapcar '- P3 P2)))
    area (- (* (car areafull) (cadr areafull)) (* (car areacorner) (cadr areacorner)))
  ); setq
  (command "_.text"
    "_mc" (mapcar '/ (mapcar '+ P1 P2) '(2 2 2))
    "" "" (strcat (rtos (/ area 10000) 2 2) " m²")
  ); command
  (princ)
); defun&lt;/LI-CODE&gt;
&lt;P&gt;If you have the virtual corner inside the column at the cut-out corner to Osnap to, you can use it and the opposite corner, or the other two corners [the ones labeled P1 &amp;amp; P2] -- either combination works, and if that hidden corner isn't there, you can snap to it with APParent-intersection snap.&lt;/P&gt;
&lt;P&gt;If there's no cutout, you can pick P3 &lt;EM&gt;anywhere on any edge&lt;/EM&gt; of the rectangular room perimeter.&lt;/P&gt;
&lt;P&gt;And it doesn't require Text already there to edit, but puts it in for you [in the current Style on the current Layer].&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 02 Aug 2021 16:36:41 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10514554#M57464</guid>
      <dc:creator>Kent1Cooper</dc:creator>
      <dc:date>2021-08-02T16:36:41Z</dc:date>
    </item>
    <item>
      <title>Re: Room Area Calculate</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10514566#M57465</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/5530556"&gt;@hak_vz&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you very much, it's ok. &lt;span class="lia-unicode-emoji" title=":hugging_face:"&gt;🤗&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 02 Aug 2021 16:25:42 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/room-area-calculate/m-p/10514566#M57465</guid>
      <dc:creator>k005</dc:creator>
      <dc:date>2021-08-02T16:25:42Z</dc:date>
    </item>
  </channel>
</rss>

