Results 1 to 3 of 3

Thread: Spline divide with VB6

  1. #1
    Member srobillard's Avatar
    Join Date
    2007-01
    Location
    Stepping into the Twilight Zone
    Posts
    10
    Login to Give a bone
    0

    Default Spline divide with VB6

    Hello Everyone,

    Here's my problem:

    I'm using AutoCAD Mechanical and Visual Basic 6. I'm trying to come up with a program
    where the user selects a spline to divide into 40 equal length parts and puts points
    at the locations where the spline is divided. (Similar to what the DIVIDE command does
    in AutoCAD). The program then saves these points in an array for other use.

    There doesn't seem to be any sort of DIVIDE object in the AutoCAD references.

    Any help or ideas is appreciated.

    Thanks in advance,
    Steve Robillard

  2. #2
    Active Member
    Join Date
    2007-06
    Posts
    97
    Login to Give a bone
    0

    Default Re: Spline divide with VB6

    I believe there are two options available:

    The first would be the use of Frank Oquendo's VLAX.cls and Curve.cls (an internet search should locate these for download) along with the appropriate (VL-LOAD-COM) added at AutoCAD startup. I haven't actually tried this method but believe it viable. It also has the advantage of working with any post R14 vesions of AutoCAD.

    The other option (demo'ed in the attached VBA project file) is the use of the GEAUTO.dll available to the Mechanical (and perhaps others) variants of AutoCAD. The appropriate references requires setting - may need altering from AcadM 2004 in attached project. Unfortunately, this project would not work in vanilla AutoCAD.
    Attached Files Attached Files

  3. #3
    Active Member
    Join Date
    2007-06
    Posts
    97
    Login to Give a bone
    0

    Default Re: Spline divide with VB6

    Another quick note:

    The project file above deals with standard Autocad splines. If the splines are imported from other software, or have had a Splinedit-FitData-Purge, the routine will fail.

    Those Splines will need the more convoluted Control Point analysis for GeNurbCurve Object creation.

Similar Threads

  1. Replies: 2
    Last Post: 2015-07-27, 05:10 AM
  2. divide by zero
    By tomcarver in forum AutoLISP
    Replies: 7
    Last Post: 2010-02-05, 05:53 PM
  3. How would I divide this?
    By nsinha73 in forum Revit Architecture - General
    Replies: 2
    Last Post: 2009-03-24, 03:16 PM
  4. divide by zero
    By tom.g in forum AutoCAD General
    Replies: 0
    Last Post: 2007-07-05, 08:28 PM
  5. divide
    By eddy.lermytte in forum Revit Architecture - General
    Replies: 13
    Last Post: 2004-12-30, 06:15 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •