I have a block that I wish to insert x number of times
The trick though is this
1)..I need to pick the start point and end point of a line
2)..Side of offset
3)..Enter the number of blocks to be inserted
4)..The blocks to be inserted have to
a) be (32..64..96mm..etc) apart
b) no less than 3" from either end of the line
c) centered on the line
Autocad2002
I know it sounds confusing and a lot of requirements but I know it can be
done
p.s. These machining sheets are for placing cam holes
Thanks,
Randy
"RANDY" <RBIL...@PREFERREDMFG.COM> wrote in message
news:9DFD0957A47BC23F...@in.WebX.maYIadrTaRb...
PS It can't hurt to ask
"Mark" <ma...@ruys.com> wrote in message
news:F5B629389872D90B...@in.WebX.maYIadrTaRb...
mark
"RANDY" <RBIL...@PREFERREDMFG.COM> wrote in message
news:9F48A02CD03E650E...@in.WebX.maYIadrTaRb...
Yes, thanks to the Basis boys!
Terry
"Terry W. Dotson" <twdo...@dotsoft.com> wrote in message
news:3D9DB4F9...@dotsoft.com...
Without reading too much into Randy's original post, it appeared
he was daring someone to write something that met his specs rather
than asking for help.
He probably would have gotten better responses with a more
polite and appropriate subject line.
Randy,
Try doing what you want manually and record the steps you take.
Your "challenge" sounds like something that could easily be
done with the OFFSET and DIVIDE command (using the block option).
After you do it manually, try coding something yourself and then
come back for help (suggest in another thread). :-)
Regards,
Doug
"Joe Melton" <joem...@pdceng.com> wrote in message
news:F5E7B1795A1000F1...@in.WebX.maYIadrTaRb...
> Randy, you'll probably get more courteous replies in the ADT customization
> newsgroup. autodesk.aec.arch-desktop.customization
> Those guys are very helpful, and I haven't seen any snide remarks like I
> just saw here.
>
<snip>
... and you don't have a clue what I'm talking about.
Terry
"Doug Broad" <dbr...@nash.cc.nc.us> wrote in message
news:4F74622C3A042D29...@in.WebX.maYIadrTaRb...
"this is not a free programming ng"
That pretty much sums up a troll.
"Frank Oquendo" <frankoatacadxdotcom> wrote in message
news:CCC7F43A165C98A5...@in.WebX.maYIadrTaRb...
> Joe Melton had this to say
> :
> > So I'm just helping Randy out since he came here for
> > help, not to listen to trolls.
>
> Did you just call Terry Dotson a troll?
>
> --
> There are 10 kinds of people:
> Those who understand binary and those who don't
> http://www.acadx.com
>
>
>
>
Did you just call Terry Dotson a troll?
It could just be a terse response to a request for free labor.
Would it not perhaps have been more "helpful" to have contributed
some code yourself perhaps rather than presuming that the poster
was being mistreated rather than being gently chided for the imperial
tone of his posted *challenge*.
Looking back, I couldn't find an instance of your "helping" someone
on this newsgroup. If you are a newcomer and want to dig in and
help others, then you aren't starting out too well.
Please stay and help but avoid personal attacks ( "Troll?" <Bwahaha>)
Doug
<snip>
I only meant it is going to be a challenge for me since I have no clue as to
where to begin.
I've got a couple of VBA or lisp ideas, and I am looking into an excell
function called mround.
Randy
"Doug Broad" <dbr...@earthlink.net> wrote in message
news:4E7F1053892ABB85...@in.WebX.maYIadrTaRb...
--
R. Robert Bell, MCSE
www.AcadX.com
If you've got some suggestion's I'd love to here them
(P.S. This is my first)
sub CalculateDistance()
Dim point1 As Variant
Dim point2 As Variant
' Get the points from the user
point1 = ThisDrawing.Utility.GetPoint _
(, vbCrLf & "First point: ")
point2 = ThisDrawing.Utility.GetPoint _
(point1, vbCrLf & "Second point: ")
' Calculate the distance between point1 and point2
Dim x As Double, y As Double, z As Double
Dim dist As Double
x = point1(0) - point2(0)
y = point1(1) - point2(1)
z = point1(2) - point2(2)
dist = Sqr((Sqr((x ^ 2) + (y ^ 2)) ^ 2) + (z ^ 2))
'Display the resulting distance
Dim distmm As Double
distmm = ((dist - 6) * 25.4)
MsgBox "The distance in mm (minus 6 in)between the points is: " _
& distmm
'qty of cams
Dim cams As Integer
cams = ThisDrawing.Utility.GetInteger("num of cams: ")
'calculate
Dim lenperqty As Integer
Dim spacing As Integer
lenperqty = (distmm / cams)
spacing = Int(lenperqty / 32) * 32
MsgBox "spaceing: " & spacing
ThisDrawing.Utility.InitializeUserInput 6, "24 34"
Dim promptStr As String
promptStr = vbCrLf & "Enter the size or (24/34/<34>):"
On Error Resume Next
Dim returnInteger As Integer
returnInteger = ThisDrawing.Utility.GetInteger(promptStr)
If Err.Description = "User input is a keyword" Then
Dim returnString As String
returnString = ThisDrawing.Utility.GetInput()
Err.Clear
Else
If returnInteger = "" Then 'If user pressed ENTER
returnString = "34" 'Set to default
Else 'Otherwise,
returnString = returnInteger
End If
End If
' insert the result
Dim path34 As String
Dim path24 As String
Dim blockRefObj As AcadBlockReference
If returnString = "34" Then
path34 = "H:\0blocks\HARDWARE\15mmcam34.dwg"
Set blockRefObj = ThisDrawing.ModelSpace.InsertBlock(point1,
"15mmcam34.dwg", 1#, 1#, 1#, 0)
Dim cam34 As Variant
cam34 = blockRefObj.ArrayRectangular(1, cams, 1, 0#, (spacing /
24.5), 0#)
End If
End Sub