<?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: New Alignment Method does not work in Revit API Forum</title>
    <link>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/9278725#M37026</link>
    <description>&lt;P&gt;What is your question, please?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;What exception is thrown?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The elements you wish to create an alignment constraint for must be pre-aligned before you create the alignment, i.e., you have to position them precisely yourself before creating the alignment.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;RTFM:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://www.revitapidocs.com/2020/b3c10008-aba6-9eee-99c9-7e05ace75796.htm" target="_blank"&gt;https://www.revitapidocs.com/2020/b3c10008-aba6-9eee-99c9-7e05ace75796.htm&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;gt;&amp;nbsp;These references must be already geometrically aligned (this function will not force them to become aligned).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please be aware of that.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;May be that is throwing the exception?&lt;/P&gt;</description>
    <pubDate>Tue, 28 Jan 2020 07:34:53 GMT</pubDate>
    <dc:creator>jeremytammik</dc:creator>
    <dc:date>2020-01-28T07:34:53Z</dc:date>
    <item>
      <title>New Alignment Method does not work</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/9277984#M37025</link>
      <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I´m working with the NewFamilyInstance method, using Lines (to create FamilyInstances) and Face (To rotate and place correctly). That works perfectly. But I have problems in some scenarios, for example, the host that has a slope.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I would need to correct the alignment, getting a new face as a reference, similar to use Align function in Revit.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is my code, I didn`t have any description of the problem, just the line that causes the exception.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;  Reference reference3 = uiDoc.Selection.PickObject(Autodesk.Revit.UI.Selection.ObjectType.Face, "Select Face 1");
  Reference reference4 = uiDoc.Selection.PickObject(Autodesk.Revit.UI.Selection.ObjectType.Face, "Select Face 2");
           
            using (Transaction transaction = new Transaction(doc, "Align"))
            {
                transaction.Start();&lt;BR /&gt;                doc.Create.NewAlignment(doc.ActiveView, reference3, reference4);
                transaction.Commit();
            }&lt;/PRE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="1.png" style="width: 999px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/722080i74811E05C4F07B34/image-size/large?v=v2&amp;amp;px=999" role="button" title="1.png" alt="1.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 27 Jan 2020 21:29:15 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/9277984#M37025</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-01-27T21:29:15Z</dc:date>
    </item>
    <item>
      <title>Re: New Alignment Method does not work</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/9278725#M37026</link>
      <description>&lt;P&gt;What is your question, please?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;What exception is thrown?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The elements you wish to create an alignment constraint for must be pre-aligned before you create the alignment, i.e., you have to position them precisely yourself before creating the alignment.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;RTFM:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://www.revitapidocs.com/2020/b3c10008-aba6-9eee-99c9-7e05ace75796.htm" target="_blank"&gt;https://www.revitapidocs.com/2020/b3c10008-aba6-9eee-99c9-7e05ace75796.htm&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;gt;&amp;nbsp;These references must be already geometrically aligned (this function will not force them to become aligned).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please be aware of that.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;May be that is throwing the exception?&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jan 2020 07:34:53 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/9278725#M37026</guid>
      <dc:creator>jeremytammik</dc:creator>
      <dc:date>2020-01-28T07:34:53Z</dc:date>
    </item>
    <item>
      <title>Re: New Alignment Method does not work</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/9279636#M37027</link>
      <description>&lt;P&gt;Hi Jeremy,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I created the elements and they are &lt;SPAN&gt;already geometrically aligned&lt;/SPAN&gt;. Also I tried with the combinations described on the documentation. (two planar faces, 2 lines and lines and point). I tried with other elements as Reference, like walls.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The exception just says the alignment cannot be created (an Internal Exception).&lt;/P&gt;&lt;P&gt;Nothing about what the problem could be. References are not nulls, and view is a 3D view. I tried in a PlanView as well.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Other suggestions ?&lt;/P&gt;&lt;P&gt;is There any method that I can use, to align elements to a face?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jan 2020 14:16:50 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/9279636#M37027</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-01-28T14:16:50Z</dc:date>
    </item>
    <item>
      <title>Re: New Alignment Method does not work</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/9279660#M37028</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;may it be that this problem is related to yours?&lt;/P&gt;&lt;P&gt;When "picking faces", this comes to my mind:&lt;/P&gt;&lt;P&gt;&lt;A href="https://forums.autodesk.com/t5/revit-api-forum/incorrect-face-normal/m-p/7108787" target="_blank"&gt;https://forums.autodesk.com/t5/revit-api-forum/incorrect-face-normal/m-p/7108787&lt;/A&gt;&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>Tue, 28 Jan 2020 14:17:56 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/9279660#M37028</guid>
      <dc:creator>Revitalizer</dc:creator>
      <dc:date>2020-01-28T14:17:56Z</dc:date>
    </item>
    <item>
      <title>Re: New Alignment Method does not work</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/9279759#M37029</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I've verified the faceNormal but both are the same.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you for the suggestion.&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jan 2020 14:42:03 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/9279759#M37029</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-01-28T14:42:03Z</dc:date>
    </item>
    <item>
      <title>Re: New Alignment Method does not work</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/9279835#M37030</link>
      <description>&lt;P&gt;Can you achieve what you need manually in the user interface?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If not, you won't be able to do it programmatically either.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The UI mostly gives more precise feedback.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jan 2020 15:10:36 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/9279835#M37030</guid>
      <dc:creator>jeremytammik</dc:creator>
      <dc:date>2020-01-28T15:10:36Z</dc:date>
    </item>
    <item>
      <title>Re: New Alignment Method does not work</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/9284953#M37031</link>
      <description>&lt;P&gt;I have two possible ideas:&lt;/P&gt;&lt;P&gt;1.&amp;nbsp; If you created the elements you shoud regenerate the document before placing the alignment.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;2.&amp;nbsp; Geometrically aligned not only means same FaceNormal also the origin of Face1 must be on Face2.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Perhaps you write a small test programm if you can find this two faces.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;In your case you could also project the endpoint of Beam2 to Face1.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 30 Jan 2020 10:02:30 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/9284953#M37031</guid>
      <dc:creator>matthias.deisboeck</dc:creator>
      <dc:date>2020-01-30T10:02:30Z</dc:date>
    </item>
    <item>
      <title>Re: New Alignment Method does not work</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/9310037#M37032</link>
      <description>&lt;P&gt;Yes, I can. With Align command works perfectly.&lt;/P&gt;</description>
      <pubDate>Tue, 11 Feb 2020 13:42:50 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/9310037#M37032</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-02-11T13:42:50Z</dc:date>
    </item>
    <item>
      <title>Re: New Alignment Method does not work</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/9311886#M37033</link>
      <description>&lt;P&gt;Hi:&lt;/P&gt;&lt;P&gt;Try this:&lt;/P&gt;&lt;P&gt;&lt;A href="https://forums.autodesk.com/t5/revit-api-forum/newalignment-to-align-family-instance-reference-plane-with/m-p/5993390" target="_blank" rel="noopener"&gt;newalignment-to-align-family-instance-reference-plane-with/m-p/5993390&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;the documentation says:&lt;BR /&gt;"These references must be already geometrically aligned (this function will not force them to become aligned)."&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;FYI:&lt;/P&gt;&lt;P&gt;The following might also be helpful:&lt;/P&gt;&lt;P&gt;&lt;A href="https://forums.autodesk.com/t5/revit-api-forum/newalignment-to-constrain-line-to-face-replicate-pick-lines-in/m-p/9256189" target="_blank" rel="noopener"&gt;https://forums.autodesk.com/t5/revit-api-forum/newalignment-to-constrain-line-to-face-replicate-pick-lines-in/m-p/9256189&lt;/A&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 12 Feb 2020 03:39:01 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/9311886#M37033</guid>
      <dc:creator>jlpgy</dc:creator>
      <dc:date>2020-02-12T03:39:01Z</dc:date>
    </item>
    <item>
      <title>Re: New Alignment Method does not work</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/10529534#M37034</link>
      <description>&lt;P&gt;Actually I have the same issue. I am trying to align Extrusion face with Reference Plane. Two references are definetly geometrically aligned. But when I try to call&amp;nbsp;&lt;SPAN style="font-family: inherit;"&gt;NewAlignment method I get the same Exception. Actually I have no idea why this happens. I've tried to regenerate document or adjust the size of the Reference plane. Still not working. =((&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Sun, 08 Aug 2021 19:21:08 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/10529534#M37034</guid>
      <dc:creator>architect.bim</dc:creator>
      <dc:date>2021-08-08T19:21:08Z</dc:date>
    </item>
    <item>
      <title>Re: New Alignment Method does not work</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/10529555#M37035</link>
      <description>&lt;P&gt;False alarm.&amp;nbsp;&lt;span class="lia-unicode-emoji" title=":grinning_squinting_face:"&gt;😆&lt;/span&gt; Actually I took the wrong face. Now works fine.&lt;/P&gt;</description>
      <pubDate>Sun, 08 Aug 2021 19:38:01 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/10529555#M37035</guid>
      <dc:creator>architect.bim</dc:creator>
      <dc:date>2021-08-08T19:38:01Z</dc:date>
    </item>
    <item>
      <title>Re: New Alignment Method does not work</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/10529607#M37036</link>
      <description>&lt;P&gt;In my case regenerating of document really helps as my Extrusion object is created in the same Transaction. Thanks&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/6330771"&gt;@matthias.deisboeck&lt;/a&gt;&amp;nbsp;for the idea!&lt;/P&gt;</description>
      <pubDate>Sun, 08 Aug 2021 20:12:47 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/new-alignment-method-does-not-work/m-p/10529607#M37036</guid>
      <dc:creator>architect.bim</dc:creator>
      <dc:date>2021-08-08T20:12:47Z</dc:date>
    </item>
  </channel>
</rss>

