DesignCAD 3D Max 2027 box
Now available

DesignCAD 2027

Hatches that follow their boundaries, an on-screen dial to turn your model, and a way to find any command by name, in a clean Windows 11 look.

Using solidsub

Started by Rodney, March 04, 2010, 07:38:16 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Rodney

I can not get the command >solidsub to work.  Here is a bit of code that I am trying to use to learn how to use BasicCAD
'Pogram to test some CAD basic operations
'First draw a cube
>box
{
   <pointxyz 0,0,0
   <pointrel 10,10,10
}
'this works okay, now cut out a tunnel thru the cub

>box
{
   <pointxyz -1,1,1
   <pointrel 12,8,8
}
'this works to here, now try to subtract the innner part cube
>solidsub
{
   <pointxyz -1,1,1
   <pointrel 0,0,0
}
'this does not work, will not subtract, gives an error

I checked out the example given in your micro command list and it does not work there either.  I am using DesignCad Max v20

Bob P

Quote from: Rodney on March 04, 2010, 07:38:16 AM
I can not get the command >solidsub to work.  Here is a bit of code that I am trying to use to learn how to use BasicCAD
'Pogram to test some CAD basic operations
'First draw a cube
>box
{
   <pointxyz 0,0,0
   <pointrel 10,10,10
}
'this works okay, now cut out a tunnel thru the cub

>box
{
   <pointxyz -1,1,1
   <pointrel 12,8,8
}
'this works to here, now try to subtract the innner part cube
>solidsub --------- Should be solidsubtract
{
   <pointxyz -1,1,1
   <pointrel 0,0,0 -------------  You're selecting the same entity. Try <pointxyz 0,0,0
}
'this does not work, will not subtract, gives an error

I checked out the example given in your micro command list and it does not work there either.  I am using DesignCad Max v20

Rodney

#2
Per the instruction in the reference, when in basic, it is solidsub, not solid subtract.  If I try to use solid subtract, I get the same error.
When a stop the program just in front of the >solidsub statement and use Cnt+U, the solid subtraction works fine using the points I used in the program.   for some reason, solidsub, subtract, solid subtract or any combination does not work when programmed as a micro.
Here is a copy of how it is used in the example:
Example:

>Cone
{

<Pointxyz 0, 0, 0
<Pointxyz 5, 0, 0
<Pointxyz 5, 20, 0

}
>Sphere
{

<Pointxyz 0, 20, 0
<Pointxyz 0, 25, 0

}
>SolidSub
{

<Pointxyz 5, 0, 0
<Pointxyz 0, 25, 0

}
Note: the example does not work either and it is copied directly from the instruction manual.

Rob S

Have you tried solidsubtract without a space between the two words??
User since forever

Bob P

Tested and works:

'First draw a cube
>box
{
   <pointxyz 0,0,0
   <pointrel 10,10,10
}
'this works okay, now cut out a tunnel thru the cub

>box
{
   <pointxyz -1,1,1
   <pointrel 12,8,8
}
'this works to here, now try to subtract the innner part cube
>solidsubtract
{
   <pointxyz -1,1,1
  <pointxyz 0,0,0
}

END:

Lar

Rodney, if you're not sure about the proper syntax for a command you can use Macro Record (tools menu) and do the command manually. When done you can open the saved macro and make any changes like exchange the absolute point values for variables.

Lar

Rodney

Thanks for the help, by using solidsubtract instead of solidsub as shown in the Macros17.hlp files shown at the beginning of this forum, all works well now.  I sure appreciate the fast and accurate response from the above gentlemen.  Rodney