<?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: Help Needed: Adding ⌀ Prefix to Vertical Linear Dimensions using iLogic script. in Inventor Programming Forum</title>
    <link>https://forums.autodesk.com/t5/inventor-programming-forum/help-needed-adding-prefix-to-vertical-linear-dimensions-using/m-p/13023605#M6225</link>
    <description>&lt;P&gt;Dim oSheet As Sheet&lt;/P&gt;&lt;P&gt;oSheet = ThisApplication.ActiveDocument.Sheets.Item(1)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;' Get the general dimensions collection&lt;/P&gt;&lt;P&gt;Dim oGeneralDimensions As GeneralDimensions&lt;/P&gt;&lt;P&gt;oGeneralDimensions = oSheet.DrawingDimensions.GeneralDimensions&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;' Loop through all general dimensions in the collection&lt;/P&gt;&lt;P&gt;For Each oDimension As GeneralDimension In oGeneralDimensions&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ' Add the Ø symbol as a prefix to the dimension text&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; oDimension.Text.FormattedText = "Ø" &amp;amp; oDimension.Text.FormattedText&lt;/P&gt;&lt;P&gt;Next&lt;/P&gt;</description>
    <pubDate>Mon, 16 Sep 2024 13:45:04 GMT</pubDate>
    <dc:creator>khadeerkruthi</dc:creator>
    <dc:date>2024-09-16T13:45:04Z</dc:date>
    <item>
      <title>Help Needed: Adding ⌀ Prefix to Vertical Linear Dimensions using iLogic script.</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/help-needed-adding-prefix-to-vertical-linear-dimensions-using/m-p/13022881#M6224</link>
      <description>&lt;P&gt;Hi everyone,&lt;/P&gt;&lt;P&gt;I’m working on an iLogic rule to add the ⌀ symbol as a prefix to all vertical linear dimensions in my drawing.&lt;BR /&gt;&lt;BR /&gt;regards;&lt;BR /&gt;&lt;SPAN&gt;khadeerkruthi&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 16 Sep 2024 07:49:56 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/help-needed-adding-prefix-to-vertical-linear-dimensions-using/m-p/13022881#M6224</guid>
      <dc:creator>khadeerkruthi</dc:creator>
      <dc:date>2024-09-16T07:49:56Z</dc:date>
    </item>
    <item>
      <title>Re: Help Needed: Adding ⌀ Prefix to Vertical Linear Dimensions using iLogic script.</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/help-needed-adding-prefix-to-vertical-linear-dimensions-using/m-p/13023605#M6225</link>
      <description>&lt;P&gt;Dim oSheet As Sheet&lt;/P&gt;&lt;P&gt;oSheet = ThisApplication.ActiveDocument.Sheets.Item(1)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;' Get the general dimensions collection&lt;/P&gt;&lt;P&gt;Dim oGeneralDimensions As GeneralDimensions&lt;/P&gt;&lt;P&gt;oGeneralDimensions = oSheet.DrawingDimensions.GeneralDimensions&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;' Loop through all general dimensions in the collection&lt;/P&gt;&lt;P&gt;For Each oDimension As GeneralDimension In oGeneralDimensions&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ' Add the Ø symbol as a prefix to the dimension text&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; oDimension.Text.FormattedText = "Ø" &amp;amp; oDimension.Text.FormattedText&lt;/P&gt;&lt;P&gt;Next&lt;/P&gt;</description>
      <pubDate>Mon, 16 Sep 2024 13:45:04 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/help-needed-adding-prefix-to-vertical-linear-dimensions-using/m-p/13023605#M6225</guid>
      <dc:creator>khadeerkruthi</dc:creator>
      <dc:date>2024-09-16T13:45:04Z</dc:date>
    </item>
    <item>
      <title>Re: Help Needed: Adding ⌀ Prefix to Vertical Linear Dimensions using iLogic script.</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/help-needed-adding-prefix-to-vertical-linear-dimensions-using/m-p/13023817#M6226</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/10206896"&gt;@khadeerkruthi&lt;/a&gt;.&amp;nbsp; I do not know how familiar you may be with the &lt;A href="https://help.autodesk.com/view/INVNTOR/2024/ENU/?guid=GUID-915B75BA-4696-4fc7-A2C6-54B2BACDE7E1" target="_blank" rel="noopener"&gt;FormattedText&lt;/A&gt; we find in drawing dimensions and notes, but they usually contain XML tags, and can be complicated to inspect and modify by code.&amp;nbsp; One way to figure out what is required is to 'reverse engineer' it.&amp;nbsp; What I mean is do it manually, the way you want it, then inspect the contents of the FormattedText property, to see what is in it.&lt;/P&gt;
&lt;P&gt;Here is a simple iLogic rule that lets you pick a dimension, then it write the value of its FormattedText to the iLogic Log window.&amp;nbsp; You can also use an InputBox, where you put the FormattedText where the 'default response' is supposed to be, to get it in the editable text box, instead of using the iLogic Logger.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="general"&gt;Dim oDDim As DrawingDimension = ThisApplication.CommandManager.Pick(SelectionFilterEnum.kDrawingDimensionFilter, "Select a drawing dimension.")
If oDDim Is Nothing Then Return
Logger.Info(vbCrLf &amp;amp; oDDim.Text.FormattedText)&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For example, if I manually add the diameter symbol in front of a regular linear dimension's text, then inspect its FormattedText, I get the following:&lt;/P&gt;
&lt;P&gt;"&amp;lt;StyleOverride Font='AIGDT'&amp;gt;n&amp;lt;/StyleOverride&amp;gt;&amp;lt;DimensionValue/&amp;gt;"&lt;/P&gt;
&lt;P&gt;Because that character is defined within that "AIGDT" Font.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 16 Sep 2024 15:12:57 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/help-needed-adding-prefix-to-vertical-linear-dimensions-using/m-p/13023817#M6226</guid>
      <dc:creator>WCrihfield</dc:creator>
      <dc:date>2024-09-16T15:12:57Z</dc:date>
    </item>
  </channel>
</rss>

