AutoCAD Inventor :: ILogic Formula - Measure Length / Width And Thickness Of A Part
Apr 26, 2012
I am trying to create a iLogic Rule that will measure the Length, Width and Thickness of a part and ut it into the custom fields we have. I am having a hard time remembering how to get it to do it from the assembly level. I want to run this on the assembly and have it populate all the parts inside of it. The code below will do it for a part but what is it I add to get it to drill down into the assembly?
Then I want to add this formula to the Stock Number iProperty = <Length> X <Width> I can get it to add the values but I can not get it to add the formula to the stock number.
I have just started to use ilogic, what i want to do is measure the length of a loop in a sketch and then use this measurement as a parameter.
I have found this rule that will measure the loop length and display it in a message box
Dim se As SketchEntity = ThisDoc.Document.ComponentDefinition.Sketches(1).SketchLines(1) MsgBox(ThisApplication.MeasureTools.GetLoopLength(se)*10 & " mm")
but i do not know how to capture the measurement as a parameter .
I want to have a Blank size custom iproperty using flat extents length and width this is what i did but gives error is there a way to get this to work the way I want it to? I dont want a Length and width to be seperated would like it all in one.
I have created a ilogic rule that should set the size and the cut length of my parts. Most of the time the rule behave as I want it to. But sometime it gives me a error. See attached picture. By the way, I have included this rule in my custom content center parts (beam's etc). The rule is:
'Turn off workfeatures ThisDoc.Document.ObjectVisibility.AllWorkFeatures = False
'check if the part has any geometry If Measure.ExtentsLength="0" Then [code]........
Is there any way to quickly measure the perimeter of a part, and also measure the length of any circles?
Our estimator is taking the drawings supplied from the customers and needs to quickly know what the cut length is around the part, and then also know the cut length of all holes or internal openings.
Lenovo Think Pad Windows 7 SP 1 64 Bit. Inventor 2013 ACAD Mechanical 2013
In an attempt to aid purchasine I have started adding a length and width parameter to our models. These parameters are converted to a purchase parameter either in square feet or per foot length depending on how the material is purchased. I would like the paramater to also automatically update if the part size is changed. I now come to a part made of a round shaft that is bent and am looking for a way to get an accurate length for it. The part is made with a sweep and the square corners are radisuesd in the sewwp. I could pull the three dimensions in the sketch and add them together to roughly appeoximate the length but that would not be quite accurate. As the number I come up with will also be used by fab to cut the rod before bending I would like it to be correct. Is there a way to generate an accurate length that can be saved as a parameter? In SWx I would create a datum axis in a sketch that could be used but I am not seeing how to do that here.
With using superelevation wizard in Civil 3d 2012, changing the lane width is not affecting the resulted values of transion length and run-off length, Is that correct ? ( as civil is using standerd AASHTO tables which assume that lane width typically is 3.6m )
Also, There is only 2 tables for 2-lanes and 4-lanes roadway, Is it for total road width or for one directon only, and what about different no. of lanes ?
know a rule to check if this dialog box sheet metal defaults "Use Thickness from Rule" is checked, and checked a rule to automatically clear since using a rule amending the plate thickness but if the box is checked catastrophic error occurs, and unchecking the rule works as expected.
In my title block I have a material section that pulls to iProperties from the model
One is material, which displays the material used in the model
and the other is manually input by me in the comments section of the model, I typically only use this field for sheet metal description, example, .125 Sheet Metal, this saves me from a drawing view to show thickness only.
In my sheet metal template I have checked the little box for the thickness model parameter so it will show up as a custom property - model.
So i can display the thickness parameter anytime the sheet metal base view is placed.
My issue is I want the thickness property to have the following with it "Sheet Metal"
But I only want this to appear if the base view is in fact sheet metal, all other parts and assemblies, this field would be blank,
So this is what I want when a sheet metal part is placed:
This is what I want to display when a part is placed:
This is what I get when anything is placed:
Sheet Metal shows up because:
I am looking for a Rule that will only apply <Thickness> Sheet Metal to my title block only if the base view is in fact a sheet metal part. Is this possible??
We use the snippets from iLogic on all of our parts to measure the length, width or height of our parts. However, we have noticed that when a 'Move Face' operation or a 'Replace Face' operation is used, the length measured does not seem to take into account the Move/Replace operations.
Are the Move/Replace operations different than other features like Extrude/Revolve? Is there something "ghost-like" about them??? The edges work fine on the drawing side, so I'm not sure what is different. Maybe it is the iLogic snippet?
In regards to it being the snippet, is there another code I can use that doesn't require specific feature or part information built in?
Inventor 2013 Product Design Suite Vault Professional 2013 Windows7 x64 Autodesk Inventor Certified Professional
I've created Custom properties, parameters, to get the outside measure of the parts and it works fine until we create and leave activated a work plane outside the part so it measures not until the end of the part but until the plane.
Is there a way to add a specific amount/length to a dimension by using a formula? For example, say I wanted to measure a length of conduit between two fittings. The clear distance between the fittings is 48" and the conduit is recessed into the fittings by 3/4" on each side. If I dimension between the fittings, normally it would read 48", but I want it to read 49-1/2" so my shop people know what length to cut.
are there any other analysis tools available to find the minimum internal wall thickness in a part? I'm aware of the cross-section tool, but that only analyzes an area the user has already noticed. In a prismatic part with several cross-holes and features (cavities), it could be easy to miss a thin spot that could give up under internal pressure just by 'eyeballing' the part with Hidden Edges turned on.
I guess I could try the 'unground and move the part thru a sectional plane' trick, but I think it would be too haphazard, especially if the weak point is not thru a principal plane.
Is there a tool I'm missing or maybe something that has been added in newer releases? Maybe this is too much analysis to ask of a modeling package.
Inventor Professional 2014 64 SP1 Windows 7 64 bit - SP1 Xeon E5-1620 16 GB Ram Quadro 2000
I´m trying to measure the base dimensions of simple geometric shapes. I started out with plates since they are easy to measure as long as they sit in 90°, 180° and 270° positions relative to the origin. Then Measure.ExtentsLength, Measure.ExtentsWidth and Measure.ExtentsHeight will give me the base dimensions of a plate.
However, if the plate sits abitrary relative to origin this will obviously fail, since Measure.Extents only measures in x,y,z
Is there any way how I get positions of the geometry that is in the part, like corners surfaces on the B-REP so I can calculate the dimensions properly for a plate. I´m not sure if this is possible with iLogic. I have a strong suspicion VB.net would be needed for this.
Another problem I have is that derived parts don´t get triggered to run a script when I change the geometry in the Multibody Part and the rule is set to run by any modelgeometry change.
How to predict what Inventor will choose for the length and width on a sheet metal flat pattern? We have similar parts (produced from iPart factory). Some of them use the small dimension for the width and some use the longer dimension for the width. This behavior seems random.
As a temporary fix we have set width = <sheet metal length> and length = <sheet metal width> on some parts to force the numbers where they should be.
I tried to attach the iPart, but it's too big .
Side note:
We DO understand how to use conditional suppression in iParts. We chose to use thicken instead to produce or exclude our notch in this case for reasons I could explain if needed. I don't think this has anything to do with our length/width issue, but wanted to included that info in case I'm wrong.
I have an assembly in which the thickness of each of the layers in an assembly are generated from a part file that is split via a sketch. I use the Make Components tool to break the part into the individual layers, which also spits out an assembly.
Is there a way to push the thickness value of these parts that will update automatically if the thickness is changed in the parent part, in order to reference this property on the drawing?
I am trying to programatically update Units of Measure on a part or document through Document Settings, but the changes are not reflected. I cannot save the file, because the file is a result of import, so I want to leave it up to the user. During import, I am recognizing what type of units the import file has, and I need to impose them on the document, and immediately show. I cannot use templates. There is a similar issue when the Units of Measure are updated manually through the screen, they are not reflected.
I`m looking for the iLogic code that can change one parameter (user defined) for each (ipt) part in assembly (iam)
The one below doesn`t work.
Sub Main Dim oApp As Inventor.Application = ThisApplication Dim oAssy As Inventor.AssemblyDocument = oApp.ActiveDocument For Each oSubDoc as Inventor.Document In oAssy.AllReferencedDocuments On Error Resume Next Parameter(oSubDoc, "FH") = 15.26 Next End Sub
In our “Parts list” (or BOM as we call it) on our .idw’s we have field for “LENGTH”. For example, we use round tubing. We would list the cut length of that piece of tube in the “LENGTH” column. As it stands now, we add “LENGTH” as a custom iproperty in the .ipt. Then in the drawing we add that property to the parts list to capture the length. This works fine, but I’m wondering if we can eliminate some steps by capturing the actual dimension from the sketch to automatically populate the “LENGTH” value. Needless to say, this would eliminate room for error (less typing) and will update the value automatically if length is changed or if the part is copied. I suppose the same would apply for “WIDTH” on sheet metal parts... How do I do this?
I'm new in use of iLogic and tried to use it by myself (and internet). But I have some difficulties.
Here is the open point, I wold like to create an assemblies with different length (and also some different part inside).
So I made some iLogic rules to make a configuration of my .iam with length selection.
I made rules to show or hide parts with is linked to the proper length.
I made rules to switch from a positional representation to another one and do the same for level of details representation and for view representation.
All is good in my .iam.
My problem is comming now. When I would like to put my .iam in a .idw in several views (corresponding to different length), my views are the all the same. I can't see one length per view even if I select the proper representation, the proper position and the proper level of detail.
At the end, all this work is to have all views length to be able to make in one drawing all length block in autocad.