Inventor General

Reply
Member
Posts: 4
Registered: ‎11-25-2012
Message 1 of 6 (227 Views)

Can I return the distance between two snapped points with vba or ilogic?

227 Views, 5 Replies
11-25-2012 01:44 PM

I'm using Inventor 2013 and would like to create a dialog box requesting the parameters for a simple rectangle and be able to snap in an assembly to get the distance for each parameter (width and depth) of the shape. Is this possible with either VBA or iLogic? I just need how to get the value...I can handle the dialog box. Thanks.

*Expert Elite*
Mark_Wigan
Posts: 436
Registered: ‎03-07-2006
Message 2 of 6 (190 Views)

Re: Can I return the distance between two snapped points with vba or ilogic?

11-27-2012 04:46 AM in reply to: m.smith

to obtain better feedback you would be better to post in the inventor customisation forum to get more info on VBA and API topics.

 

not sure what you mean when you say " able to snap in an assembly"...

 

 

best regards,
- Mark

PDSU 2014 Windows 7, 64bit. (please consider Kudos or Tag as Solved if your issue is sorted)

Member
Posts: 4
Registered: ‎11-25-2012
Message 3 of 6 (177 Views)

Re: Can I return the distance between two snapped points with vba or ilogic?

11-27-2012 11:36 AM in reply to: m.smith

Mark,

 

Thanks for the suggestion. By snap in assy I mean simply that I could select in the model the vertices I need the distance between for my ipart.

*Expert Elite*
Mark_Wigan
Posts: 436
Registered: ‎03-07-2006
Message 4 of 6 (148 Views)

Re: Can I return the distance between two snapped points with vba or ilogic?

12-01-2012 06:06 AM in reply to: m.smith

i do recall some code i used once... perhaps it is still around, if you search the forum for "the vba measure toolmeasure tool" or something like that.

 

i will see if i still have it and let you know. it was a useful macro before inventor improved its own measuring functionality. i think it had a LOT of coding in it from memory!

 

(around the early years of 2000 i probably saw it).

 

we should probably move this to the inventor customisation part of the forum...ps-

best regards,
- Mark

PDSU 2014 Windows 7, 64bit. (please consider Kudos or Tag as Solved if your issue is sorted)

*Expert Elite*
Mark_Wigan
Posts: 436
Registered: ‎03-07-2006
Message 5 of 6 (139 Views)

Re: Can I return the distance between two snapped points with vba or ilogic?

12-01-2012 06:46 AM in reply to: Mark_Wigan

just did a search and found this... i think it is (was) the one i was referring to.

 

doesn't look like we will find it without further searching in the customer files area noted in the following thread;

 

http://forums.autodesk.com/t5/Autodesk-Inventor-Customization/The-Ruler-file-moved/m-p/754723/highli...

 

 

best regards,
- Mark

PDSU 2014 Windows 7, 64bit. (please consider Kudos or Tag as Solved if your issue is sorted)

Member
Posts: 4
Registered: ‎11-25-2012
Message 6 of 6 (102 Views)

Re: Can I return the distance between two snapped points with vba or ilogic?

12-05-2012 03:55 AM in reply to: m.smith

Thanks, Mark! I will pursue your link. I have found a piece of code that allows me to make the snaps and show the value in the measuring tool, just as you manually can. I am beginning to get into iLogic and just need to figure out how to return the measurement value from the tool. If I knew the name of that value when it appears onscreen, I think I could bring it into the code then apply it to the iPart. I guess all I need to do is explore the tool properties more.

 

Just trying to accelerate my learning curve! I'm implementing and adapting Inventor for the US in collaboration with our Belgian partners, so I'm working the candle from both ends and the middle. Fun but tons of stuff of all sorts to do at once!

 

Thanks for the help.

 

BTW, the code that sets up the tool and allows me to click in the model is fairly brief. I can post it if you'd like to see it. I can do that when I get back to the office tomorrow.

 

You are not logged in.

Log into access your profile, ask and answer questions, share ideas and more. Haven't signed up yet? Register

Announcements
Are you interested in helping shape the Autodesk Community?
We’re looking at a few different ways to improve the “All Forums” landing page and need your feedback! If interested, please take a few minutes to fill out the following Usability Study. Thank you for your time!

Need installation help?

Start with some of our most frequented solutions to get help installing your software.

Ask the Community


Inventor Exchange Apps

Created by the community for the community, Autodesk Exchange Apps for Autodesk Inventor helps you achieve greater speed, accuracy, and automation from concept to manufacturing.

Connect with Inventor

Twitter

Facebook

Blogs

Pinterest

Youtube