<?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: automatic texts in object in Libraries &amp; objects</title>
    <link>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110801#M31933</link>
    <description>Thanks again for trying to help Matt, &lt;BR /&gt;
but its not working atleast with AC10 1176 FIN version. &lt;BR /&gt;
 &lt;BR /&gt;
Its not wrapping the text or not wrapping as it should.  &lt;BR /&gt;
It can for instance split the word from middle,  &lt;BR /&gt;
which simple autotext is not doing.  &lt;BR /&gt;
 &lt;BR /&gt;
To clear my intentions I put some code from my object. &lt;BR /&gt;
Its in metric system, I'm sorry, put please try and put &lt;BR /&gt;
it to the layout and give a very long name to a drawing. &lt;BR /&gt;
 &lt;BR /&gt;

&lt;PRE&gt;&lt;I&gt;
&lt;/I&gt;!text width scale is working: 
    scnimip=1 
!aligment full justification is not working: 
    alig = 4 
!This line is representing a titleblock line, which is messing the word wrap. 
    Line2 0,0.05,0.3,0.05 
 
!if piirnimi = "Piirustusten nimet" then  
		paragraph		"AC_PRG_56"     alig, 0, 0, 0, 1 
		"&amp;lt;DRAWINGNAME&amp;gt;" 
		endparagraph 
		textblock	"AC_TEXTBLOCK_56" 60, 1, 0, scnimip, 1, 1,  
		"AC_PRG_56" 
		richtext2		0.09423, 0.05, "AC_TEXTBLOCK_56" 
!endif 
!pen ac_huomiopen 
!if piirnimi = "Planssin nimi" then  
!		paragraph		"AC_PRG_1"      alig, 0, 0, 0, 1 
!		"&amp;lt;LAYOUTNAME&amp;gt;" 
!		endparagraph 
!		textblock	"AC_TEXTBLOCK_1" 60, 1, 0, scnimip, 1, 1,  
!		"AC_PRG_1" 
!		richtext2	0.09423, 0.05, "AC_TEXTBLOCK_1" 
!endif 
!if piirnimi = "Alaryhmän nimi+Planssin nimi" then  
!		paragraph		"AC_PRG_71"      alig, 0, 0, 0, 1 
!		"&amp;lt;SUBSETNAME&amp;gt; &amp;lt;LAYOUTNAME&amp;gt;" 
!		endparagraph 
!		textblock	"AC_TEXTBLOCK_71" 60, 1, 0, scnimip, 1, 1,  
!		"AC_PRG_71" 
!		richtext2	0.09423, 0.05, "AC_TEXTBLOCK_71" 
!endif 
!if piirnimi = "Muu nimi" then 
!		text2 0.09423, 0.0507, omanimi 
!endif 
!pen         ac_textpen
&lt;/PRE&gt;</description>
    <pubDate>Fri, 30 Mar 2007 06:40:43 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2007-03-30T06:40:43Z</dc:date>
    <item>
      <title>automatic texts in object</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110790#M31922</link>
      <description>&lt;DIV class="actalk-migrated-content"&gt;&lt;T&gt;Hi, &lt;BR /&gt;
 &lt;BR /&gt;
Is there a way to make title block object so, that &lt;BR /&gt;
it will not list drawings done in 1:1 scale? &lt;BR /&gt;
 &lt;BR /&gt;
Problem occurs when adding a 1:1 scale drawing  &lt;BR /&gt;
(like automatic drawing list) to the layout.  &lt;BR /&gt;
Automatic text lists all scales which can be  &lt;BR /&gt;
confusing when inserted lists and tables are not "real" drawings. &lt;BR /&gt;
 &lt;BR /&gt;
So is it possible to split &amp;lt;DRAWINGSCALE&amp;gt; parameter so that &lt;BR /&gt;
if scale is for example 1:1 object will not list it? &lt;BR /&gt;
 &lt;BR /&gt;
could u help me with the code plz?&lt;/T&gt;&lt;/DIV&gt;</description>
      <pubDate>Mon, 12 Mar 2007 10:53:53 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110790#M31922</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-03-12T10:53:53Z</dc:date>
    </item>
    <item>
      <title>Re: automatic texts in object</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110791#M31923</link>
      <description>I am not sure what you are looking for here.&lt;BR /&gt;
&lt;BR /&gt;
If you don't want a drawing title just select "No Title" in the dialog settings.&lt;BR /&gt;
&lt;BR /&gt;
If you don't want it in numbered in the layout's drawing list, then uncheck "Include Drawing in ID Sequence"&lt;BR /&gt;
&lt;BR /&gt;
Sorry if I have not understood. There is a way to tell within a drawing title the scale of the associated drawing, but it is a bit of a pain since the information is provided as a formatted string rather than a numerical value.&lt;BR /&gt;
&lt;BR /&gt;
If you do need this function in the title the code is something like this:
&lt;PRE&gt;IF STRSTR(AC_DrawingScale, "1:1") &amp;gt; 0 THEN...&lt;/PRE&gt;
This tests to see if the substring "1:1" is contained within the returned value.</description>
      <pubDate>Mon, 12 Mar 2007 20:07:29 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110791#M31923</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-03-12T20:07:29Z</dc:date>
    </item>
    <item>
      <title>Re: automatic texts in object</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110792#M31924</link>
      <description>Hi, and thanks for the reply.  &lt;BR /&gt;
I'm sorry I know I wasn't very clear with this, but I quess  &lt;BR /&gt;
your answer was close. I'm not such an expert with gdl,  &lt;BR /&gt;
so I can't figure it out yet.  &lt;BR /&gt;
  &lt;BR /&gt;
So I'm placing a title text (object) in to the layout. That text  &lt;BR /&gt;
is listing all the scales of the drawings placed in the layout,  &lt;BR /&gt;
just like automatic text &amp;lt;DRAWINGSCALE&amp;gt; does. Problem  &lt;BR /&gt;
is that it also lists tables, schedules, etc., and gives 1:1 scale for  &lt;BR /&gt;
them. For example: 1:50, 1:1. That's confusing if you  &lt;BR /&gt;
only have 1:50 scaled drawings placed in the layout.  &lt;BR /&gt;
  &lt;BR /&gt;
Here is a poor example what kind of an object I'm after for:  &lt;BR /&gt;
  &lt;BR /&gt;
IF STRSTR("&amp;lt;DRAWINGSCALE&amp;gt;", "1:1") &amp;gt; 0 THEN   &lt;BR /&gt;
text2		0, 0, "Happy" ! here should be new text string without 1:1 scale  &lt;BR /&gt;
else   &lt;BR /&gt;
text2		0, 0, "&amp;lt;DRAWINGSCALE&amp;gt;"  &lt;BR /&gt;
endif &lt;BR /&gt;
 &lt;BR /&gt;
So basically the formula should split &amp;lt;DRAWINGSCALE&amp;gt; -parameter according commas and determine if some string part value is "1:1" and remove it from the string....</description>
      <pubDate>Tue, 13 Mar 2007 07:56:57 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110792#M31924</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-03-13T07:56:57Z</dc:date>
    </item>
    <item>
      <title>Re: automatic texts in object</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110793#M31925</link>
      <description>That looks right. Is it not working for you?</description>
      <pubDate>Tue, 13 Mar 2007 14:19:45 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110793#M31925</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-03-13T14:19:45Z</dc:date>
    </item>
    <item>
      <title>Re: automatic texts in object</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110794#M31926</link>
      <description>heh. actually no.  &lt;BR /&gt;
  &lt;BR /&gt;
The result is not even "happy", as it should be with 1:50 and 1:1  &lt;BR /&gt;
drawings placed in the layout.  &lt;BR /&gt;
  &lt;BR /&gt;
Maybe its because of this &amp;lt;DRAWINGSCALE&amp;gt; is global parameter, which is text rather than numbers?   &lt;BR /&gt;
I also tried this with 1:50 and 1:1 drawings placed in  &lt;BR /&gt;
layout:  &lt;BR /&gt;
  &lt;BR /&gt;
n = SPLIT ("&amp;lt;DRAWINGSCALE&amp;gt;", "%n:%n, %n:%n", num1, dot1, scl_1, com1, num2, dot2, scl_2)  &lt;BR /&gt;
PRINT num1, com1, scl_1, dot1, num2, com2, scl_2   &lt;BR /&gt;
  &lt;BR /&gt;
Printed result was a punch of zeroes. So is it impossible to get values out  &lt;BR /&gt;
from &amp;lt;DRAWINGSCALE&amp;gt; ??</description>
      <pubDate>Thu, 15 Mar 2007 07:32:07 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110794#M31926</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-03-15T07:32:07Z</dc:date>
    </item>
    <item>
      <title>Re: automatic texts in object</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110795#M31927</link>
      <description>&lt;BLOCKQUOTE&gt;So is it impossible to get values out&lt;BR /&gt;
from &amp;lt;DRAWINGSCALE&amp;gt;&lt;/BLOCKQUOTE&gt;
Yes: Impossible. &lt;IMG src="https://community.graphisoft.com/legacyfs/online/emojis/icon_sad.gif" style="display : inline;" /&gt;</description>
      <pubDate>Thu, 15 Mar 2007 10:19:05 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110795#M31927</guid>
      <dc:creator>Frank Beister</dc:creator>
      <dc:date>2007-03-15T10:19:05Z</dc:date>
    </item>
    <item>
      <title>Re: automatic texts in object</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110796#M31928</link>
      <description>&lt;BLOCKQUOTE&gt;cejava1 wrote:&lt;BR /&gt; So is it impossible to get values out  &lt;BR /&gt;
from &amp;lt;DRAWINGSCALE&amp;gt; ??&lt;/BLOCKQUOTE&gt;

I just looked closer and realized that you are using the autotext &amp;lt;DRAWINGSCALE&amp;gt; and not the parameter name DrawingScale (without the carets).&lt;BR /&gt;
&lt;BR /&gt;
From the parameter you can extract stings to test for different scales and assign numerical vales accordingly. It's a pain but, it works.</description>
      <pubDate>Thu, 15 Mar 2007 14:50:07 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110796#M31928</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-03-15T14:50:07Z</dc:date>
    </item>
    <item>
      <title>Re: automatic texts in object</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110797#M31929</link>
      <description>Argh. This turned out to be really tricky.    &lt;BR /&gt;
   &lt;BR /&gt;
Because of many variables in project its point to make an object where user can choose if values are coming from Project Info Box or from ie. Layout name or from Subsetname.   &lt;BR /&gt;
 &lt;BR /&gt;
Otherwise it seems to work just fine, but too wide text strings with autotext really creates a problem. That happens especially if trying to list individual drawing names and their scales in layout. Textbox and Paragraph commands are not working properly with autotext. Its weird because it looks alright in object's Real 2D-window, but when object is placed in layout text is just in single row or rows are tiled funny. Normal text can be splitted to different rows quite easily. &lt;BR /&gt;
 &lt;BR /&gt;
This forum have had this conversation already with earlier versions of AC, but is it still so that it is impossible to get a numeric return for drawing scales and -names in the layout? And and I mean a single object not a Title Type attached to single drawing.  &lt;BR /&gt;
 &lt;BR /&gt;
If this is the case there is not really any real use for Info Box and there is a great lack in the program.</description>
      <pubDate>Thu, 29 Mar 2007 07:56:28 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110797#M31929</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-03-29T07:56:28Z</dc:date>
    </item>
    <item>
      <title>Re: automatic texts in object</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110798#M31930</link>
      <description>I have extracted the following script out of a very old object of mine, because there have been questions for this a few times before. It converts  scales into string and back to numeric. Try, if it fits for your needs.&lt;BR /&gt;

&lt;PRE&gt;!»» Example with automatic scale string of drawing stamps
scaleS=AC_DrawingScale

!»» CONVERT SCALE-STRING TO NUMERIC
scaleN=0
!»» Cut of "M" at the beginning. Not needed.
s=STRSTR(scaleS,"M")
IF s THEN scaleS=STRSUB(scaleS,s+1,STRLEN(scaleS)-s)
!»» Imperial or metric?
s=STRSTR(scaleS,"=")
!»» Converting ...
IF s THEN
  !»» Scale notation is imperial
  sts=SPLIT(STRSUB(scaleS,1,s-1),"%n",lengthR)
  sts=SPLIT(STRSUB(scaleS,s+1,STRLEN(scaleS)-s),"%n",lengthP)
  IF lengthR THEN scaleN=lengthP/lengthR ELSE scaleN=MAX(lengthP,0)
  ELSE
  !»» Scale notation is metric
  IF NOT(scaleS="auto") THEN
    s=STRSTR((scaleS,":")
    IF s THEN
      sts=SPLIT(STRSUB(scaleS,1,s-1),"%n",lengthR)
      sts=SPLIT(STRSUB(scaleS,s+1,STRLEN(scaleS)-s),"%n",lengthP)
      IF lengthR THEN scaleN=lengthP/lengthR ELSE scaleN=MAX(lengthP,0)
      ELSE
      sts=SPLIT(scaleS,"%n",scaleN)
      ENDIF
    ENDIF
  ENDIF
!»» scaleN contains the divisor of the scale.


!»» CONVERT NUMERIC TO IMPERIAL NOTATION
IF scaleN&amp;lt;2000 AND NOT(scaleN&amp;gt;=100 AND FRA(scaleN/10)&amp;lt;0.001 ) THEN
  scaleI=STR("%^.128fi",1" * 12/scaleN)+´=1'0"´
  ELSE
  scaleI=´1"=´+STR("%^.32ffi",scaleN*1")
  ENDIF
!»» scaleI contains the imperial scale string.

!»» CONVERT NUMERIC TO METRIC NOTATION
praefix="M "
IF scaleN&amp;lt;1 THEN
  scaleM=praefix+STR("%^.0m",1/scaleN)+":1"
  ELSE
  scaleM=praefix+"1:"+STR("%^.0m",scaleN)
  ENDIF
!»» scaleM contains the metric scale string.

!»» PRINT RESULTS
txt="»»"+scaleS+"««"
txt=txt+" »»"+STR("%.3",scaleN)+"««"
txt=txt+" »»"+scaleI+"««"
txt=txt+" »»"+scaleM+"««"
TEXT2 0,0,txt
END&lt;/PRE&gt;</description>
      <pubDate>Thu, 29 Mar 2007 10:58:49 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110798#M31930</guid>
      <dc:creator>Frank Beister</dc:creator>
      <dc:date>2007-03-29T10:58:49Z</dc:date>
    </item>
    <item>
      <title>Re: automatic texts in object</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110799#M31931</link>
      <description>Thanks for your great code Mr.F.B!  &lt;BR /&gt;
  &lt;BR /&gt;
I tried it as Title Type attached to single drawing and like you said it worked perfectly and took needed strings out from the drawing.  &lt;BR /&gt;
However, unless I'm an idiot, as it might be the case in here, this object can only work as a Title Type object and has to be attached to the drawing.  &lt;BR /&gt;
I'm looking for normal object wich lists all scales of all drawings placed in the layout.  &lt;BR /&gt;
With autotext &amp;lt;drawingscale&amp;gt; it works, but long string has to be divided to many rows of text. &lt;BR /&gt;
 &lt;BR /&gt;
So if its possible to do with normal object class, it needs maybe REQUEST-command for AC_DrawingScale parameter?  &lt;BR /&gt;
Wich can not be done, right? arghh..</description>
      <pubDate>Thu, 29 Mar 2007 12:11:13 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110799#M31931</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-03-29T12:11:13Z</dc:date>
    </item>
    <item>
      <title>Re: automatic texts in object</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110800#M31932</link>
      <description>&lt;BLOCKQUOTE&gt;cejava1 wrote:&lt;BR /&gt;With autotext &amp;lt;drawingscale&amp;gt; it works, but long string has to be divided to many rows of text. &lt;/BLOCKQUOTE&gt;

Use the PARAGRAPH and RICHTEXT functions to get automatic word wrap.</description>
      <pubDate>Thu, 29 Mar 2007 23:59:04 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110800#M31932</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-03-29T23:59:04Z</dc:date>
    </item>
    <item>
      <title>Re: automatic texts in object</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110801#M31933</link>
      <description>Thanks again for trying to help Matt, &lt;BR /&gt;
but its not working atleast with AC10 1176 FIN version. &lt;BR /&gt;
 &lt;BR /&gt;
Its not wrapping the text or not wrapping as it should.  &lt;BR /&gt;
It can for instance split the word from middle,  &lt;BR /&gt;
which simple autotext is not doing.  &lt;BR /&gt;
 &lt;BR /&gt;
To clear my intentions I put some code from my object. &lt;BR /&gt;
Its in metric system, I'm sorry, put please try and put &lt;BR /&gt;
it to the layout and give a very long name to a drawing. &lt;BR /&gt;
 &lt;BR /&gt;

&lt;PRE&gt;&lt;I&gt;
&lt;/I&gt;!text width scale is working: 
    scnimip=1 
!aligment full justification is not working: 
    alig = 4 
!This line is representing a titleblock line, which is messing the word wrap. 
    Line2 0,0.05,0.3,0.05 
 
!if piirnimi = "Piirustusten nimet" then  
		paragraph		"AC_PRG_56"     alig, 0, 0, 0, 1 
		"&amp;lt;DRAWINGNAME&amp;gt;" 
		endparagraph 
		textblock	"AC_TEXTBLOCK_56" 60, 1, 0, scnimip, 1, 1,  
		"AC_PRG_56" 
		richtext2		0.09423, 0.05, "AC_TEXTBLOCK_56" 
!endif 
!pen ac_huomiopen 
!if piirnimi = "Planssin nimi" then  
!		paragraph		"AC_PRG_1"      alig, 0, 0, 0, 1 
!		"&amp;lt;LAYOUTNAME&amp;gt;" 
!		endparagraph 
!		textblock	"AC_TEXTBLOCK_1" 60, 1, 0, scnimip, 1, 1,  
!		"AC_PRG_1" 
!		richtext2	0.09423, 0.05, "AC_TEXTBLOCK_1" 
!endif 
!if piirnimi = "Alaryhmän nimi+Planssin nimi" then  
!		paragraph		"AC_PRG_71"      alig, 0, 0, 0, 1 
!		"&amp;lt;SUBSETNAME&amp;gt; &amp;lt;LAYOUTNAME&amp;gt;" 
!		endparagraph 
!		textblock	"AC_TEXTBLOCK_71" 60, 1, 0, scnimip, 1, 1,  
!		"AC_PRG_71" 
!		richtext2	0.09423, 0.05, "AC_TEXTBLOCK_71" 
!endif 
!if piirnimi = "Muu nimi" then 
!		text2 0.09423, 0.0507, omanimi 
!endif 
!pen         ac_textpen
&lt;/PRE&gt;</description>
      <pubDate>Fri, 30 Mar 2007 06:40:43 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110801#M31933</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-03-30T06:40:43Z</dc:date>
    </item>
    <item>
      <title>Re: automatic texts in object</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110802#M31934</link>
      <description>I still wanted to add that I noticed autotext is wrapping just fine in layout if it is in object and placed in master layout or in model space.  &lt;BR /&gt;
 &lt;BR /&gt;
Then it "calculates" rows and wrapping is working, but when object is placed directly to the  layout, it wont be wrapped.  &lt;BR /&gt;
 &lt;BR /&gt;
Thats really awkward because it would be nice have titleblock object in layout and therefore be able to control different variations.</description>
      <pubDate>Thu, 12 Apr 2007 13:38:08 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110802#M31934</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-04-12T13:38:08Z</dc:date>
    </item>
    <item>
      <title>Re: automatic texts in object</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110803#M31935</link>
      <description>I'm sorry I haven't time to test your code, but it looks OK from what I recall (the PARAGRAPH &amp;gt; TEXTBLOCK &amp;gt; RICHTEXT method is a bit torturous).&lt;BR /&gt;
&lt;BR /&gt;
I have used it for title types and it has wrapped just fine but not for general purpose parts placed on the layouts. Perhaps there is a scaling issue since the layout is at 1:1.</description>
      <pubDate>Thu, 12 Apr 2007 14:24:33 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/automatic-texts-in-object/m-p/110803#M31935</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-04-12T14:24:33Z</dc:date>
    </item>
  </channel>
</rss>

