<?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>tema Re: Rotate Existing Curve Object w/ API en FeatureCAM Forum</title>
    <link>https://forums.autodesk.com/t5/featurecam-forum/rotate-existing-curve-object-w-api/m-p/8383035#M3817</link>
    <description>&lt;P&gt;The origin axis as 0,0,0 is something i tried before. The thing that i changed was the exclusive parameter of the Select method to false and that seemed to work. For reference:&lt;/P&gt;&lt;PRE&gt;Sub Main

	Dim app As Application
	Dim doc As FMDocument

	Set app = Application
	Set doc = app.ActiveDocument

	'made a simple curve within the turning document for rotation around Y axis
	doc.curves.Item(1).Select(True, False)
	doc.curves.Selected.XFormRotate(False, False, 0, 90, eXFT_RotateCenterYAxis, 0,0,0)


End Sub&lt;/PRE&gt;&lt;P&gt;Thanks for your help!&lt;/P&gt;</description>
    <pubDate>Tue, 06 Nov 2018 13:40:21 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2018-11-06T13:40:21Z</dc:date>
    <item>
      <title>Rotate Existing Curve Object w/ API</title>
      <link>https://forums.autodesk.com/t5/featurecam-forum/rotate-existing-curve-object-w-api/m-p/8359622#M3782</link>
      <description>&lt;P&gt;I having a bit of difficulty trying to rotate an existing curve object from the API. The FMCurves object has a reference to a method "XFormRotate" containing the same arguments found in the UI Transform dialog box used to rotate it from FeatureCAM. At the time of this transformation, there is only one existing curve in the document. Document.curves.Item(1).Name returns the name of my only curve, so I know the object isn't null, but when I try to run Document.curves.XFormRotate, nothing happens. Any ideas?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Thu, 25 Oct 2018 16:14:53 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/featurecam-forum/rotate-existing-curve-object-w-api/m-p/8359622#M3782</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-10-25T16:14:53Z</dc:date>
    </item>
    <item>
      <title>Re: Rotate Existing Curve Object w/ API</title>
      <link>https://forums.autodesk.com/t5/featurecam-forum/rotate-existing-curve-object-w-api/m-p/8382862#M3814</link>
      <description>&lt;P&gt;I think you have to select the curve first.&lt;BR /&gt;Rotation is applied to all selected object.&lt;BR /&gt;&lt;BR /&gt;...curve.select(true, true)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 06 Nov 2018 12:34:47 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/featurecam-forum/rotate-existing-curve-object-w-api/m-p/8382862#M3814</guid>
      <dc:creator>klaus.gibbe</dc:creator>
      <dc:date>2018-11-06T12:34:47Z</dc:date>
    </item>
    <item>
      <title>Re: Rotate Existing Curve Object w/ API</title>
      <link>https://forums.autodesk.com/t5/featurecam-forum/rotate-existing-curve-object-w-api/m-p/8382975#M3815</link>
      <description>&lt;P&gt;I still cant get anything to rotate. See simple code below:&lt;/P&gt;&lt;PRE&gt;Sub Main

	Dim app As Application
	Dim doc As FMDocument

	Set app = Application
	Set doc = app.ActiveDocument

	'made a simple curve within the turning document for rotation around Y axis
	doc.curves.Item(1).Select(True, True)
	doc.curves.XFormRotate(False, False, 0, 90, eXFT_RotateCenterYAxis)


End Sub&lt;/PRE&gt;&lt;P&gt;The select in this case works. I tried multiple variations of the xFormRotate method including:&lt;/P&gt;&lt;PRE&gt;doc.curves.Selected.XFormRotate(....)
doc.Features.XFormRotate(...)
doc.Features.Selected.XFormRotate(...)&lt;/PRE&gt;&lt;P&gt;No such luck.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 06 Nov 2018 13:16:03 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/featurecam-forum/rotate-existing-curve-object-w-api/m-p/8382975#M3815</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-11-06T13:16:03Z</dc:date>
    </item>
    <item>
      <title>Re: Rotate Existing Curve Object w/ API</title>
      <link>https://forums.autodesk.com/t5/featurecam-forum/rotate-existing-curve-object-w-api/m-p/8383020#M3816</link>
      <description>&lt;P&gt;There&amp;nbsp;are several possibilities to do the rotation.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;a)&lt;/P&gt;
&lt;P&gt;select to objects you want to rotate by curves/models/features.item(i).select(true, false) and then rotate all selected objects in a document by&lt;/P&gt;
&lt;P&gt;doc.XFormRotate(...)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;or b)&lt;/P&gt;
&lt;P&gt;select object(s) of a specific type like curve.select(true, false) and rotate all selected curves only by&lt;/P&gt;
&lt;P&gt;doc.curves.Selected.XFormRotate(...)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;One other thing to think about is the position of the rotation axis. You want to rotate around Y axis.&lt;/P&gt;
&lt;P&gt;Where is the origin of the rotation axis?&lt;BR /&gt;Maybe you should do something like this:&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;doc.XFormRotate(false,false,0,angle,eXFT_RotateCenterYAxis, posX, 0, posZ,null)&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;where posX/Z is the origin of the y axis.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 06 Nov 2018 13:33:04 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/featurecam-forum/rotate-existing-curve-object-w-api/m-p/8383020#M3816</guid>
      <dc:creator>klaus.gibbe</dc:creator>
      <dc:date>2018-11-06T13:33:04Z</dc:date>
    </item>
    <item>
      <title>Re: Rotate Existing Curve Object w/ API</title>
      <link>https://forums.autodesk.com/t5/featurecam-forum/rotate-existing-curve-object-w-api/m-p/8383035#M3817</link>
      <description>&lt;P&gt;The origin axis as 0,0,0 is something i tried before. The thing that i changed was the exclusive parameter of the Select method to false and that seemed to work. For reference:&lt;/P&gt;&lt;PRE&gt;Sub Main

	Dim app As Application
	Dim doc As FMDocument

	Set app = Application
	Set doc = app.ActiveDocument

	'made a simple curve within the turning document for rotation around Y axis
	doc.curves.Item(1).Select(True, False)
	doc.curves.Selected.XFormRotate(False, False, 0, 90, eXFT_RotateCenterYAxis, 0,0,0)


End Sub&lt;/PRE&gt;&lt;P&gt;Thanks for your help!&lt;/P&gt;</description>
      <pubDate>Tue, 06 Nov 2018 13:40:21 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/featurecam-forum/rotate-existing-curve-object-w-api/m-p/8383035#M3817</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-11-06T13:40:21Z</dc:date>
    </item>
  </channel>
</rss>

