<?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: Where is the helix length ??? in VBA Forum</title>
    <link>https://forums.autodesk.com/t5/vba-forum/where-is-the-helix-length/m-p/1726791#M32057</link>
    <description>"TotalLength"&lt;BR /&gt;
&lt;LEORONCETTI&gt; wrote in message news:5259536@discussion.autodesk.com...&lt;BR /&gt;
Hey, I can´t believe there is no property for helix length !!!&lt;BR /&gt;
Will I have to calculate it ???&lt;BR /&gt;
&lt;BR /&gt;
Does anyone has the formulas or code for a general helix like autocad draws &lt;BR /&gt;
???&lt;BR /&gt;
&lt;BR /&gt;
Thanks !&lt;BR /&gt;
&lt;BR /&gt;
Leonardo Roncetti&lt;/LEORONCETTI&gt;</description>
    <pubDate>Sun, 06 Aug 2006 19:06:25 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2006-08-06T19:06:25Z</dc:date>
    <item>
      <title>Where is the helix length ???</title>
      <link>https://forums.autodesk.com/t5/vba-forum/where-is-the-helix-length/m-p/1726789#M32055</link>
      <description>Hey, I can´t believe there is no property for helix length !!!&lt;BR /&gt;
Will I have to calculate it ???&lt;BR /&gt;
&lt;BR /&gt;
Does anyone has the formulas or code for a general helix like autocad draws ???&lt;BR /&gt;
&lt;BR /&gt;
Thanks !&lt;BR /&gt;
&lt;BR /&gt;
Leonardo Roncetti</description>
      <pubDate>Fri, 04 Aug 2006 18:27:07 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vba-forum/where-is-the-helix-length/m-p/1726789#M32055</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2006-08-04T18:27:07Z</dc:date>
    </item>
    <item>
      <title>Re: Where is the helix length ???</title>
      <link>https://forums.autodesk.com/t5/vba-forum/where-is-the-helix-length/m-p/1726790#M32056</link>
      <description>Just an idea only...&lt;BR /&gt;
Get the helix volume and than divide it on section area&lt;BR /&gt;
&lt;BR /&gt;
Fatty&lt;BR /&gt;
&lt;BR /&gt;
~'J'~</description>
      <pubDate>Fri, 04 Aug 2006 19:53:47 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vba-forum/where-is-the-helix-length/m-p/1726790#M32056</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2006-08-04T19:53:47Z</dc:date>
    </item>
    <item>
      <title>Re: Where is the helix length ???</title>
      <link>https://forums.autodesk.com/t5/vba-forum/where-is-the-helix-length/m-p/1726791#M32057</link>
      <description>"TotalLength"&lt;BR /&gt;
&lt;LEORONCETTI&gt; wrote in message news:5259536@discussion.autodesk.com...&lt;BR /&gt;
Hey, I can´t believe there is no property for helix length !!!&lt;BR /&gt;
Will I have to calculate it ???&lt;BR /&gt;
&lt;BR /&gt;
Does anyone has the formulas or code for a general helix like autocad draws &lt;BR /&gt;
???&lt;BR /&gt;
&lt;BR /&gt;
Thanks !&lt;BR /&gt;
&lt;BR /&gt;
Leonardo Roncetti&lt;/LEORONCETTI&gt;</description>
      <pubDate>Sun, 06 Aug 2006 19:06:25 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vba-forum/where-is-the-helix-length/m-p/1726791#M32057</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2006-08-06T19:06:25Z</dc:date>
    </item>
    <item>
      <title>Re: Where is the helix length ???</title>
      <link>https://forums.autodesk.com/t5/vba-forum/where-is-the-helix-length/m-p/1726792#M32058</link>
      <description>Hi Leonardo&lt;BR /&gt;
Here is something similar on what you want&lt;BR /&gt;
Give this a try&lt;BR /&gt;
&lt;BR /&gt;
Dim objArr(0) As AcadEntity&lt;BR /&gt;
Dim opath As Acad3DPolyline&lt;BR /&gt;
Dim ocirc As AcadCircle&lt;BR /&gt;
Dim oSol As Acad3DSolid&lt;BR /&gt;
Dim RegVar As Variant&lt;BR /&gt;
Dim oReg As AcadRegion&lt;BR /&gt;
Dim rad As Double&lt;BR /&gt;
Dim dia As Double&lt;BR /&gt;
Dim pth As Double&lt;BR /&gt;
Dim hgt As Double&lt;BR /&gt;
Dim ang As Double&lt;BR /&gt;
Dim pi As Double&lt;BR /&gt;
Dim da As Double&lt;BR /&gt;
Dim dz As Double&lt;BR /&gt;
Dim dh As Double&lt;BR /&gt;
Dim dr As Double&lt;BR /&gt;
Dim num, iCnt, i, j As Integer&lt;BR /&gt;
Dim cent(0 To 2) As Double&lt;BR /&gt;
Dim varPt As Variant&lt;BR /&gt;
Dim norm(0 To 2) As Variant&lt;BR /&gt;
Dim stp(0 To 2) As Double&lt;BR /&gt;
Dim strpt As String&lt;BR /&gt;
Dim ptArr() As Double&lt;BR /&gt;
Dim orig As Variant&lt;BR /&gt;
Dim xax(0 To 2) As Double&lt;BR /&gt;
Dim yax(0 To 2) As Double&lt;BR /&gt;
Dim ucsName As String&lt;BR /&gt;
Dim leng As Double&lt;BR /&gt;
Dim curUCS As AcadUCS&lt;BR /&gt;
Dim ucsMatx As Variant&lt;BR /&gt;
Sub Helix()&lt;BR /&gt;
rad = 100# ' outer radius of helix&lt;BR /&gt;
dia = 25# ' wire diameter&lt;BR /&gt;
pth = 25# 'pitch&lt;BR /&gt;
num = 4 'number of rotation&lt;BR /&gt;
&lt;BR /&gt;
hgt = pth * num&lt;BR /&gt;
pi = Atn(1) * 4&lt;BR /&gt;
dz = pth / 128 'number of division per rotation&lt;BR /&gt;
dh = dz&lt;BR /&gt;
da = pi / 64&lt;BR /&gt;
dr = da&lt;BR /&gt;
cent(0) = 0#: cent(1) = 0#: cent(2) = 0#:&lt;BR /&gt;
&lt;BR /&gt;
iCnt = 0&lt;BR /&gt;
On Error GoTo sayme&lt;BR /&gt;
&lt;BR /&gt;
Do While dz &amp;lt;= hgt&lt;BR /&gt;
varPt = ThisDrawing.Utility.PolarPoint(cent, da, rad)&lt;BR /&gt;
ReDim Preserve ptArr(iCnt + 2)&lt;BR /&gt;
ptArr(iCnt) = varPt(0)&lt;BR /&gt;
ptArr(iCnt + 1) = varPt(1)&lt;BR /&gt;
&lt;BR /&gt;
ptArr(iCnt + 2) = dz&lt;BR /&gt;
dz = dz + dh&lt;BR /&gt;
da = da + dr&lt;BR /&gt;
iCnt = iCnt + 3&lt;BR /&gt;
Loop&lt;BR /&gt;
leng = Sqr((ptArr(3) ^ 2) + (ptArr(4) ^ 2) + (ptArr(5) ^ 2))&lt;BR /&gt;
norm(0) = ptArr(3)&lt;BR /&gt;
norm(1) = ptArr(4)&lt;BR /&gt;
norm(2) = ptArr(5)&lt;BR /&gt;
&lt;BR /&gt;
ThisDrawing.SendCommand "_SHADEMODE" &amp;amp; vbCr &amp;amp; "_2" &amp;amp; vbCr&lt;BR /&gt;
Set opath = ThisDrawing.ModelSpace.Add3DPoly(ptArr)&lt;BR /&gt;
&lt;BR /&gt;
strpt = Replace(CStr(norm(0)), ",", ".") &amp;amp; "," &amp;amp; _&lt;BR /&gt;
Replace(CStr(norm(1)), ",", ".") &amp;amp; "," &amp;amp; _&lt;BR /&gt;
Replace(CStr(norm(2)), ",", ".")&lt;BR /&gt;
ThisDrawing.SendCommand "_-VIEW" &amp;amp; vbCr &amp;amp; "_RIGHT" &amp;amp; vbCr&lt;BR /&gt;
ThisDrawing.SendCommand "_UCS" &amp;amp; vbCr &amp;amp; "_N" &amp;amp; vbCr &amp;amp; "_ZA" &amp;amp; vbCr &amp;amp; "0.0,0.0,0.0" &amp;amp; vbCr &amp;amp; strpt &amp;amp; vbCr &amp;amp; vbCr&lt;BR /&gt;
&lt;BR /&gt;
stp(0) = ptArr(0): stp(1) = ptArr(1): stp(2) = ptArr(2)&lt;BR /&gt;
&lt;BR /&gt;
Set ocirc = ThisDrawing.ModelSpace.AddCircle(stp, dia / 2)&lt;BR /&gt;
Set objArr(0) = ocirc&lt;BR /&gt;
RegVar = ThisDrawing.ModelSpace.AddRegion(objArr)&lt;BR /&gt;
Set oReg = RegVar(0)&lt;BR /&gt;
&lt;BR /&gt;
Set oSol = ThisDrawing.ModelSpace.AddExtrudedSolidAlongPath(oReg, opath)&lt;BR /&gt;
ThisDrawing.SendCommand "_UCS" &amp;amp; vbCr &amp;amp; "_World" &amp;amp; vbCr&lt;BR /&gt;
ThisDrawing.SendCommand "_SHADEMODE" &amp;amp; vbCr &amp;amp; "_G" &amp;amp; vbCr&lt;BR /&gt;
sayme:&lt;BR /&gt;
MsgBox Err.Description&lt;BR /&gt;
End Sub&lt;BR /&gt;
&lt;BR /&gt;
Fatty&lt;BR /&gt;
&lt;BR /&gt;
~'J'~</description>
      <pubDate>Tue, 08 Aug 2006 13:08:49 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vba-forum/where-is-the-helix-length/m-p/1726792#M32058</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2006-08-08T13:08:49Z</dc:date>
    </item>
    <item>
      <title>Re: Where is the helix length ???</title>
      <link>https://forums.autodesk.com/t5/vba-forum/where-is-the-helix-length/m-p/1726793#M32059</link>
      <description>Sub HelixLength()&lt;BR /&gt;
&lt;BR /&gt;
Dim retObj As Object&lt;BR /&gt;
Dim retPnt As Variant&lt;BR /&gt;
Dim Helix As AcadHelix&lt;BR /&gt;
&lt;BR /&gt;
ThisDrawing.Utility.GetEntity retObj, retPnt, "Select helix: "&lt;BR /&gt;
&lt;BR /&gt;
Set Helix = retObj&lt;BR /&gt;
&lt;BR /&gt;
MsgBox Helix.TotalLength&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
End Sub</description>
      <pubDate>Thu, 10 Aug 2006 20:43:45 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vba-forum/where-is-the-helix-length/m-p/1726793#M32059</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2006-08-10T20:43:45Z</dc:date>
    </item>
    <item>
      <title>Re: Where is the helix length ???</title>
      <link>https://forums.autodesk.com/t5/vba-forum/where-is-the-helix-length/m-p/1726794#M32060</link>
      <description>Oh, my bad&lt;BR /&gt;
You talking about Helix object as in 2007 version&lt;BR /&gt;
I have A2005 only &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;BR /&gt;
&lt;BR /&gt;
~'J'~</description>
      <pubDate>Thu, 10 Aug 2006 21:52:16 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vba-forum/where-is-the-helix-length/m-p/1726794#M32060</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2006-08-10T21:52:16Z</dc:date>
    </item>
    <item>
      <title>Re: Where is the helix length ???</title>
      <link>https://forums.autodesk.com/t5/vba-forum/where-is-the-helix-length/m-p/1726795#M32061</link>
      <description>That´s OK !!!&lt;BR /&gt;
You code is very useful. &lt;BR /&gt;
I have a kind of helix that has different quantity of segments per length, so Acad2007 does not handle it.&lt;BR /&gt;
&lt;BR /&gt;
Thanks !!!</description>
      <pubDate>Fri, 11 Aug 2006 11:53:29 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vba-forum/where-is-the-helix-length/m-p/1726795#M32061</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2006-08-11T11:53:29Z</dc:date>
    </item>
    <item>
      <title>Re: Where is the helix length ???</title>
      <link>https://forums.autodesk.com/t5/vba-forum/where-is-the-helix-length/m-p/1726796#M32062</link>
      <description>Glad if this helps, but I don't tested this code&lt;BR /&gt;
extensively, perhaps, might be any mistakes there&lt;BR /&gt;
&lt;BR /&gt;
Happy computing,&lt;BR /&gt;
&lt;BR /&gt;
Fatty&lt;BR /&gt;
&lt;BR /&gt;
~'J'~</description>
      <pubDate>Fri, 11 Aug 2006 12:20:35 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vba-forum/where-is-the-helix-length/m-p/1726796#M32062</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2006-08-11T12:20:35Z</dc:date>
    </item>
  </channel>
</rss>

