<?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: Rooms/Room tags not updating in views after floors are painted programmatica in Revit API Forum</title>
    <link>https://forums.autodesk.com/t5/revit-api-forum/rooms-room-tags-not-updating-in-views-after-floors-are-painted/m-p/8868225#M41505</link>
    <description>&lt;P&gt;Hi, I just did that. It didn't work. Nothing changed.&lt;/P&gt;</description>
    <pubDate>Mon, 24 Jun 2019 11:46:07 GMT</pubDate>
    <dc:creator>asattar.md</dc:creator>
    <dc:date>2019-06-24T11:46:07Z</dc:date>
    <item>
      <title>Rooms/Room tags not updating in views after floors are painted programmatically</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/rooms-room-tags-not-updating-in-views-after-floors-are-painted/m-p/8868010#M41500</link>
      <description>&lt;P&gt;We have written a plugin that automatically applies a different material to floors.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;We call&lt;/P&gt;&lt;PRE&gt;doc.Paint(element.Id, face, materialId)&lt;/PRE&gt;&lt;P&gt;for all the faces of the element. This code is updating the materials (as we can see from the material browser).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The problem the tag that describes this material is not getting updated in the sheets. The tag is a keynote tag.&lt;/P&gt;&lt;P&gt;What we have found is moving the tag slightly (manually) updates the tag. It shows the right value.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="tag.jpg" style="width: 214px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/650186iFA93E31261EA4C36/image-size/large?v=v2&amp;amp;px=999" role="button" title="tag.jpg" alt="tag.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Actual value should be Botticino (defined as keynote for the material). It shows Kota Blue even after calling the doc.Paint method. However, if we move the tag slightly, it updates to Botticino (as shown in the screenshot).&lt;/P&gt;&lt;P&gt;Are we missing some method that needs to be called for the views to refresh?&lt;/P&gt;</description>
      <pubDate>Mon, 24 Jun 2019 09:48:25 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/rooms-room-tags-not-updating-in-views-after-floors-are-painted/m-p/8868010#M41500</guid>
      <dc:creator>asattar.md</dc:creator>
      <dc:date>2019-06-24T09:48:25Z</dc:date>
    </item>
    <item>
      <title>Re: Rooms/Room tags not updating in views after floors are painted programmatica</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/rooms-room-tags-not-updating-in-views-after-floors-are-painted/m-p/8868019#M41501</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You can use the regenerate method revit document to reflect all the changes.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;doc.Regenerate();&lt;/PRE&gt;</description>
      <pubDate>Mon, 24 Jun 2019 09:54:55 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/rooms-room-tags-not-updating-in-views-after-floors-are-painted/m-p/8868019#M41501</guid>
      <dc:creator>thannaingoo.api</dc:creator>
      <dc:date>2019-06-24T09:54:55Z</dc:date>
    </item>
    <item>
      <title>Re: Rooms/Room tags not updating in views after floors are painted programmatica</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/rooms-room-tags-not-updating-in-views-after-floors-are-painted/m-p/8868069#M41502</link>
      <description>&lt;P&gt;Tried that. Has no effect. Similarly uidoc.RefreshActiveView also has no effect.&lt;/P&gt;</description>
      <pubDate>Mon, 24 Jun 2019 10:06:18 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/rooms-room-tags-not-updating-in-views-after-floors-are-painted/m-p/8868069#M41502</guid>
      <dc:creator>asattar.md</dc:creator>
      <dc:date>2019-06-24T10:06:18Z</dc:date>
    </item>
    <item>
      <title>Re: Rooms/Room tags not updating in views after floors are painted programmatica</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/rooms-room-tags-not-updating-in-views-after-floors-are-painted/m-p/8868086#M41503</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;you wrote "move the tag slightly".&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What about moving the tag by a XYZ.Zero vector?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Revitalizer&lt;/P&gt;</description>
      <pubDate>Mon, 24 Jun 2019 10:15:18 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/rooms-room-tags-not-updating-in-views-after-floors-are-painted/m-p/8868086#M41503</guid>
      <dc:creator>Revitalizer</dc:creator>
      <dc:date>2019-06-24T10:15:18Z</dc:date>
    </item>
    <item>
      <title>Re: Rooms/Room tags not updating in views after floors are painted programmatica</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/rooms-room-tags-not-updating-in-views-after-floors-are-painted/m-p/8868094#M41504</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Below is a reference for you.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="https://forums.autodesk.com/t5/revit-api-forum/removepaint-does-not-update-view/td-p/7360608" target="_blank"&gt;https://forums.autodesk.com/t5/revit-api-forum/removepaint-does-not-update-view/td-p/7360608&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 24 Jun 2019 10:18:42 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/rooms-room-tags-not-updating-in-views-after-floors-are-painted/m-p/8868094#M41504</guid>
      <dc:creator>thannaingoo.api</dc:creator>
      <dc:date>2019-06-24T10:18:42Z</dc:date>
    </item>
    <item>
      <title>Re: Rooms/Room tags not updating in views after floors are painted programmatica</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/rooms-room-tags-not-updating-in-views-after-floors-are-painted/m-p/8868225#M41505</link>
      <description>&lt;P&gt;Hi, I just did that. It didn't work. Nothing changed.&lt;/P&gt;</description>
      <pubDate>Mon, 24 Jun 2019 11:46:07 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/rooms-room-tags-not-updating-in-views-after-floors-are-painted/m-p/8868225#M41505</guid>
      <dc:creator>asattar.md</dc:creator>
      <dc:date>2019-06-24T11:46:07Z</dc:date>
    </item>
    <item>
      <title>Re: Rooms/Room tags not updating in views after floors are painted programmatica</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/rooms-room-tags-not-updating-in-views-after-floors-are-painted/m-p/8868227#M41506</link>
      <description>&lt;P&gt;Thanks for the link. I had gone through it and tried doc.Regenerate() and uidoc.RefreshActiveView()&lt;/P&gt;</description>
      <pubDate>Mon, 24 Jun 2019 11:47:29 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/rooms-room-tags-not-updating-in-views-after-floors-are-painted/m-p/8868227#M41506</guid>
      <dc:creator>asattar.md</dc:creator>
      <dc:date>2019-06-24T11:47:29Z</dc:date>
    </item>
    <item>
      <title>Re: Rooms/Room tags not updating in views after floors are painted programmatica</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/rooms-room-tags-not-updating-in-views-after-floors-are-painted/m-p/8869895#M41507</link>
      <description>&lt;P&gt;The funny thing is it's very inconsistent.&lt;/P&gt;&lt;P&gt;When I use RevitPythonShell, get the element and try to do&lt;/P&gt;&lt;PRE&gt;e.TagHeadPosition = e.TagHeadPosition.Add(XYZ.Zero)&lt;/PRE&gt;&lt;P&gt;and then commit the transaction, it works sometimes, sometimes it doesn't.&lt;/P&gt;&lt;P&gt;But when I run it as part of a larger plugin, it doesn't work at all.&lt;/P&gt;</description>
      <pubDate>Tue, 25 Jun 2019 05:34:20 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/rooms-room-tags-not-updating-in-views-after-floors-are-painted/m-p/8869895#M41507</guid>
      <dc:creator>asattar.md</dc:creator>
      <dc:date>2019-06-25T05:34:20Z</dc:date>
    </item>
    <item>
      <title>Re: Rooms/Room tags not updating in views after floors are painted programmatica</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/rooms-room-tags-not-updating-in-views-after-floors-are-painted/m-p/8875476#M41508</link>
      <description>&lt;P&gt;We have fixed it!&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;The trick was to first make the view of the tag active and then copy paste it in the same place. We deleted the older tag. I believe, if we just move it slightly also it will work as long as the view is active.&lt;/P&gt;</description>
      <pubDate>Thu, 27 Jun 2019 06:51:28 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/rooms-room-tags-not-updating-in-views-after-floors-are-painted/m-p/8875476#M41508</guid>
      <dc:creator>asattar.md</dc:creator>
      <dc:date>2019-06-27T06:51:28Z</dc:date>
    </item>
    <item>
      <title>Re: Rooms/Room tags not updating in views after floors are painted programmatica</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/rooms-room-tags-not-updating-in-views-after-floors-are-painted/m-p/11647317#M41509</link>
      <description>&lt;P&gt;I had a similar issue adding tags to some detail items. I could add the tags in the correct positions, but if I manually moved them later, they would move back to their original basepoint and offset from there. Regenerating didn't help, but I found that placing the tags and then wiggling them did the trick. Here's my python code for future reference. I'm using Revit 2021.1.&lt;/P&gt;&lt;LI-CODE lang="python"&gt;t = DB.Transaction(doc, 'Add Tags')
t.Start()

for elem in elements:

    # Get desired tag location as an offset from the element you are tagging
    tag_loc = elem.Location.Point.Add(DB.XYZ(0,-2.25,0))

    # Create tag
    new_tag = DB.IndependentTag.Create(
        doc,
        view_id,
        DB.Reference(elem),
        False,
        DB.TagMode.TM_ADDBY_CATEGORY,
        DB.TagOrientation.Horizontal,
        tag_loc
    )

    # Optionally, set tag type
    #new_tag.ChangeTypeId(DB.ElementId(desired_type_id))

    # Wiggle tag
    DB.ElementTransformUtils.MoveElement(doc, new_tag.Id, DB.XYZ(2,0,0))
    DB.ElementTransformUtils.MoveElement(doc, new_tag.Id, DB.XYZ(-2,0,0))

t.Commit()&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 29 Dec 2022 19:13:57 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/rooms-room-tags-not-updating-in-views-after-floors-are-painted/m-p/11647317#M41509</guid>
      <dc:creator>PerryLackowski</dc:creator>
      <dc:date>2022-12-29T19:13:57Z</dc:date>
    </item>
  </channel>
</rss>

