MAKE THIS Solidworks MACRO and EARN A $10 reward (woohoo)

Heya guys,

I'd like to be in an assembly, select a part, hit a key, and have the

3 planes of the selected part mated to the assembly's planes. sounds straightforward, although I tried recording it and couldnt get it to work. Preferably the macro would work on older versions of solidworks (my older versions use .SWP files, if thats any help) You can post it here for all the share and I'll paypal you the $10.

-Mike

Reply to
mike
Loading thread data ...

What is the default name for the Front, Top and Right planes for you?

TOP engtran.com

Reply to
manager

Mike,

Can you share the codes and let some modify that for you. Also what version of SW you are working on.

Deepak Gupta SW2007 SP5.0 SW2009 SP3.0

formatting link

Reply to
Engineer

At my current billable rate, $10 barely covers the time it takes to blow this off.

Reply to
That70sTick

Oh go on tick, you know we looooooove you! lolo

:>)

Reply to
pfarnham

At least he's not begging for a free macro. I do appreciate that he's not asking for a handout. All too often, lending a hand to a hapless would-be programmer turns into a tearful request for hours of free work.

The most important lesson I learned about SW macro programming is that there's no money in it.

I may do it. If I do, I won't ask for the money.

Meanwhile, a possible approach: Traverse the features of the assembly and the component to select the first three planes of each. Check the normal direction of each plane and match planes according to normal direction. Apply coincident mates to plane sets.

Matching pairs by plane normals avoids the problem of relying on specific names for the planes.

Reply to
That70sTick

If you take the top three planes from the feature tree (like I said but you failed to read and/or understand), they will be the principle planes, so there will be no such inconsistencies.

Reply to
That70sTick

Wow, thanks for the great response guys. The discussion about planes pointed out that I didn't give you enough detail. I want the front plane of the part mated to the front plane of the assembly, top to the top, right to the right, all orientations the same. You should be able to create an assembly, create an empty part, and mate the empty part to the assembly and have the "front view" in either the part or assembly be the same.

and if $10 is unreasonable (I thought this would be a quick no brainer, perhaps I was wrong) then name your price...

Thanks again for the responses.

-Mike

Reply to
mike

You could also check at the SolidWorks forums, or at angelsix.com.. Luke over at angelsix is a great asset to the SolidWorks community.

Reply to
tnik

Why not just grab the part and drop it over the origin in assembly so it get fix to it

Yes there will not be any planes constrained but u will get the same result and SW will have less to calculate

That is how I start all my assemblies

ps.

Just in case ... I don't have PayPal account :)

Reply to
mr.T

PolyTech Forum website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.