Community
PowerShape Forum
Welcome to Autodesk’s PowerShape Forums. Share your knowledge, ask questions, and explore popular PowerShape topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Macro or a VB script that cuts the curves automatically in every corner's

3 REPLIES 3
SOLVED
Reply
Message 1 of 4
marcelolink
658 Views, 3 Replies

Macro or a VB script that cuts the curves automatically in every corner's

Hey Pals,
I've been in trouble trying to create a macro or a VB script that cuts the curves automatically in every corner's (where I put the red dots to demonstrate it).
I've been trying to use the magnitude and the tangent to test every dot of the curve but I didn't have succeeded (maybe it's because the curves are projected in a not plane surface).
Wish someone could help me.

 

Thanks in advanced.
Marcelo Link.

3 REPLIES 3
Message 2 of 4

Hi @marcelolink,

Thanks for contacting the Autodesk Community Forum. 

Can you please share a sample macro for which you want edit along with sample model? Or if you are looking for full macro then can you please elaborate the exact requirement in details so that we can have look? You can also record a small video for the operation that you want to execute using macro or VB script so that it would help to understand exact requirement here. 

Alternatively if it contains some confidential data  then you can create a case from your Autodesk Account or you can contact local re-seller so that they can create case on behalf of you.

Thank you for your time and co-operation,

Best Regards,  



Jitendra Chaudhari.
Message 3 of 4

Thank you Jitendra!!!

I think I solved my issues to identifying the points where I would like to separate the curve... I ended up using the information from:
[name].point[number].ENTRY_tangent.azimuth x [name].point[number].EXIT_tangent.azimuth

 

But now I have another problem (a small one)..
I selected a Curve and then record a macro where I use the Cut function...

Now I would like to replace this:

 

/// edit raise limit cuts
<b1l> 141,954725 277,191492 -16,854599 0,120541 -0,736776 -0,665305 0,714573 0 0 0 500 10000 -10000 -0,987217 0,104274 0,120541 0 -0,018572 0,675882 -0,736776 0 -0,158297 -0,729596 -0,665305 0 233,536426 -218,967632 175,903262 1 @Anonymous 277 - Nº 35
<bu> 141,954725 277,191492 -16,854599 0,120541 -0,736776 -0,665305 0,714573 0 0 0 500 10000 -10000 -0,987217 0,104274 0,120541 0 -0,018572 0,675882 -0,736776 0 -0,158297 -0,729596 -0,665305 0 233,536426 -218,967632 175,903262 1 @Anonymous 277 - Nº 35
SELECT CLEARLIST ///

 

With specific posicion coordinates extracted from the compcurve[name].point[number].x , compcurve[name].point[number].y , compcurve[name].point[number].z...

Something like this:

 

/// edit raise limit cuts
20 20 20 (coordination)
SELECT CLEARLIST/// 

  

I know how to extract the coordenates but I don't know how to use them with the Cut function...or even how to simulate a mouse click on this coordinates.

 

Thank you again.

Message 4 of 4
marcelolink
in reply to: marcelolink

I think I handled my problem using the hard way... as you can see at the video the vb program must test every dot of the curve to find out where occurs the discontinuities. Then the program delete every dots before the discontinuity point and every dots after the NEXT discontinuity point ...

 

It takes a little while, however I think is far better than identify and cut the curves manually....
If anyone find out another way to do this I will be glad.
tHANK yOU.

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report