Visual Basic Customization

Visual Basic Customization

Reply
New Member
oldieuser9
Posts: 2
Registered: ‎09-20-2012
Message 1 of 3 (156 Views)
Accepted Solution

loft and the ugly sendcommand

156 Views, 2 Replies
09-20-2012 07:03 AM

hello everyone,

 

i know you should never use sendcommand but its  last chance saloon time.

 

i already have created 2 circles:

 

Set objCircle1 = ThisDrawing.ModelSpace.AddCircle(objLine.startpoint, dblDia1 / 2)

Set objCircle2 = ThisDrawing.ModelSpace.AddCircle(objLine.endpoint, dblDia / 2)

 

now i would like to loft between them, they are not concentric else i would use AddRevolvedSolid.

 

how do i structure the loft command? i guess i need to send the id or handle of these circles

 

so i tried

 

strHandle1 = objCircle1.Handle

strHandle2 = objCircle2.Handle

 

this doesnt work:

 

ThisDrawing.SendCommand "loft" & vbCr &  strHandle1 &  strHandle2 & vbCr & vbCr

 

how do i correctly send objects to the command line?

 

any useful input would be wonderful! thanks

 

Hi,

 

try this with your handles instead of mine from my small sample

 Dim tHandleStr1 As String: tHandleStr1 = "25E"
Dim tHandleStr2 As String: tHandleStr2 = "25D"
Call ThisDrawing.SendCommand("_LOFT" & vbCr & "(handent """ & tHandleStr1 & """)" & vbCr & "(handent """ & tHandleStr2 & """)" & vbCr & vbCr & vbCr)

 

 

- alfred -

*Expert Elite*
Alfred.NESWADBA
Posts: 9,207
Registered: ‎06-29-2007
Message 2 of 3 (148 Views)

Re: loft and the ugly sendcommand

09-20-2012 10:29 AM in reply to: oldieuser9

Hi,

 

try this with your handles instead of mine from my small sample

   Dim tHandleStr1 As String: tHandleStr1 = "25E"
   Dim tHandleStr2 As String: tHandleStr2 = "25D"
   Call ThisDrawing.SendCommand("_LOFT" & vbCr & "(handent """ & tHandleStr1 & """)" & vbCr & "(handent """ & tHandleStr2 & """)" & vbCr & vbCr & vbCr)

 

 

- alfred -

-------------------------------------------------------------------------
Alfred NESWADBA
Ingenieur Studio HOLLAUS ... www.hollaus.at
-------------------------------------------------------------------------
New Member
oldieuser9
Posts: 2
Registered: ‎09-20-2012
Message 3 of 3 (137 Views)

Re: loft and the ugly sendcommand

09-20-2012 11:58 PM in reply to: oldieuser9

thanks very much, that works fine. the devil is in the details!

Post to the Community

Have questions about Autodesk products? Ask the community.

New Post
Need installation help?

Start with some of our most frequented solutions or visit the Installation and Licensing Forum to get help installing your software.