<?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 Change MText height using IF statement in C# in AutoCAD Forum</title>
    <link>https://forums.autodesk.com/t5/autocad-forum/change-mtext-height-using-if-statement-in-c/m-p/9357454#M111415</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I'm trying to change the MText height and position using an &lt;STRONG&gt;if&lt;/STRONG&gt; statement, so that when the user chooses a number (e.g 100) the text changes its height to 5. The problem is that value doesn't change it always stays on the default value and position inside the &lt;STRONG&gt;else&lt;/STRONG&gt; statement. I tried the &lt;STRONG&gt;switch&lt;/STRONG&gt; cases but still the same problem...&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;if (scaleValue == "100")
                    {
                        MText mText = new MText();

                        mText.Location = new Point3d(pointFourX+5, pointThreeY - 10, 0);
                        mText.Contents = $"{circles}T14,2φ8(12→26) ";
                        mText.TextHeight = 5;
                        mText.LineSpaceDistance = 33;
                        acBlkTblRec.AppendEntity(mText);
                        acTrans.AddNewlyCreatedDBObject(mText, true);
                    }
                    else
                    {
                        MText mText = new MText();

                        mText.Location = new Point3d(5, pointSevenY - 50, 0);
                        mText.Contents = $"{circles}T14,2φ8(12→26) ";
                        mText.TextHeight = 20;
                        mText.LineSpaceDistance = 33;
                        acBlkTblRec.AppendEntity(mText);
                        acTrans.AddNewlyCreatedDBObject(mText, true);
                    }&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;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 04 Mar 2020 11:33:42 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2020-03-04T11:33:42Z</dc:date>
    <item>
      <title>Change MText height using IF statement in C#</title>
      <link>https://forums.autodesk.com/t5/autocad-forum/change-mtext-height-using-if-statement-in-c/m-p/9357454#M111415</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I'm trying to change the MText height and position using an &lt;STRONG&gt;if&lt;/STRONG&gt; statement, so that when the user chooses a number (e.g 100) the text changes its height to 5. The problem is that value doesn't change it always stays on the default value and position inside the &lt;STRONG&gt;else&lt;/STRONG&gt; statement. I tried the &lt;STRONG&gt;switch&lt;/STRONG&gt; cases but still the same problem...&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;if (scaleValue == "100")
                    {
                        MText mText = new MText();

                        mText.Location = new Point3d(pointFourX+5, pointThreeY - 10, 0);
                        mText.Contents = $"{circles}T14,2φ8(12→26) ";
                        mText.TextHeight = 5;
                        mText.LineSpaceDistance = 33;
                        acBlkTblRec.AppendEntity(mText);
                        acTrans.AddNewlyCreatedDBObject(mText, true);
                    }
                    else
                    {
                        MText mText = new MText();

                        mText.Location = new Point3d(5, pointSevenY - 50, 0);
                        mText.Contents = $"{circles}T14,2φ8(12→26) ";
                        mText.TextHeight = 20;
                        mText.LineSpaceDistance = 33;
                        acBlkTblRec.AppendEntity(mText);
                        acTrans.AddNewlyCreatedDBObject(mText, true);
                    }&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;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 04 Mar 2020 11:33:42 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/autocad-forum/change-mtext-height-using-if-statement-in-c/m-p/9357454#M111415</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-03-04T11:33:42Z</dc:date>
    </item>
    <item>
      <title>Re: Change MText height using IF statement in C#</title>
      <link>https://forums.autodesk.com/t5/autocad-forum/change-mtext-height-using-if-statement-in-c/m-p/9357635#M111416</link>
      <description>&lt;P&gt;@Anonymous&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Better post your question to some customization forum &lt;A href="https://forums.autodesk.com/t5/autocad-customization/ct-p/AutoCADTopic1" target="_blank" rel="noopener"&gt;HERE&lt;/A&gt;&amp;nbsp;. There are folks that understand the C.&lt;/P&gt;
&lt;DIV id="gtx-trans" style="position: absolute; left: 502px; top: 86px;"&gt;
&lt;DIV class="gtx-trans-icon"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;/DIV&gt;</description>
      <pubDate>Wed, 04 Mar 2020 12:34:38 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/autocad-forum/change-mtext-height-using-if-statement-in-c/m-p/9357635#M111416</guid>
      <dc:creator>ВeekeeCZ</dc:creator>
      <dc:date>2020-03-04T12:34:38Z</dc:date>
    </item>
  </channel>
</rss>

