AutoCAD Inventor :: Color Change With ILogic?

Jun 27, 2012

I am using Inventor 2012:  I have a table with different part numbers. I want to create an iLogic rule to change the color of second solid body in my part for a specific part number.

This is what I did.

If iProperties.Value("Project", "Part Number") = "F22111796" Then
 Feature.Color("plastic")= "Gray"
ElseIf iProperties.Value("Project", "Part Number") = "F22111796V" Then
 Feature.Color("plastic")= "Gray (Dark)"
ElseIf iProperties.Value("Project", "Part Number") = "F22111796N" Then
 Feature.Color("plastic")= "Gray (Light)"
Else
 Feature.Color("plastic")="Gray"
End If

However it does not change the color of the second solid body when I make the part number active.

View 1 Replies


ADVERTISEMENT

AutoCAD Inventor :: Ilogic To Change Model Color / Appearance

Sep 17, 2013

When I open a drawing, i want to be able to change the appearance of its part model.I can do it in part itself using iProperties.PartColor.

But I want to do it from inside the drawing.

View 1 Replies View Related

AutoCAD Inventor :: 2012 - ILogic Code To Change Drawing Layer Color

Aug 27, 2011

How to change the color of layer that will be used within a drawing files for special purposes.

Ideally the code will make the color Red, but change to Black prior to printing.

The "logic" behind the code currently is to differentiate a layer called "Burn" to a highly visible color for the purpose of review by others then, prior to printing, change the color to Black.  The firm I'm currently working for uses gray-scale B sided printers only.  The firm currently uses Blue for dimension and extension lines so to produce drawings that portray both type of objects "lightly".

View 2 Replies View Related

AutoCAD Inventor :: Change Drawing Scale With ILogic Upon Parameter Change

Jul 8, 2013

I have a spreadsheet and iLogic driven mater assy to generate different iterations.

I would like to change the scale of a base view on a drawing based on a parameter in my assembly. The idea is to get iLogic to change the view using a simple If / Else statement.

This is what I tried:

If Parameter("0 Generic Assembly v2.2.iam.BP") < 1570 Then
ActiveSheet.View("VIEW1").Scale = 1/8
Else
ActiveSheet.View("VIEW1").Scale = 1/10
EndIf

So basically the value of "BP" parameter (excel parameter in my assy) would drive the scale of the views. But its not working. Is it actually a sensible method? Can I use in the drawing environment the excel parameters in my assembly?

This is the error message I get when the rule is run:

"Error in rule: View Scale, in document: 0 Generic Assembly v2.2.idw

Unspecified error (Exception from HRESULT: 0x80004005 (E_FAIL))" 

Also using the same thinking I use iLogic to populate the drg number field on the drawing based on an excel parameter. The rule works but does not always updates the drawing no upon the parameter change or update/rebuild commands.

View 1 Replies View Related

AutoCAD Inventor :: Using ILogic To Change Parameter

Mar 26, 2013

When I import a part from content center, a tube in this case, I get a length parameter called <PL>.

I am using this parameter in the parts lists, so it shows "=Outer diameter x thickness x <PL>"

However I don't want trailing zeros, leading zeros or units string to be shown.

I know I can open the parameters window, right click the parameter, then click custom property format and then uncheck these boxes and its fine.

But I want to know if there is a smarter way to do this, like creating a rule to execute on all the parts?

I have around 500 pipes with the parameter <PL> that needs to be changed.

View 6 Replies View Related

AutoCAD Inventor :: ILogic To Change Sheet Name

Oct 31, 2013

I've seen snipppets of code to get the Sheet name but is there a way to set it via code? I'm thinking it might be useful to set the sheet names to the chosen sheet format (as opposed to just 'Sheet').

I'm sprucing up my drawing template...

Rule #1 is for selecting sheet format (which title block/sheet size / orientation)
Rule #2 is for setting iproperty values to populate the titleblock with info. (if required)
Rule #1 was based on code from S.Bixler & inventortrenches
Rule#2 was based on more code taken from here.

View 2 Replies View Related

AutoCAD Inventor :: Change Row Of IAssembly Using ILogic

Nov 11, 2013

Issue between an i-assembly and i-Logic. So, I have an assembly that includes some extra components that are not always needed and therefore an i-Logic rule takes the decision whether these will be suppressed or not.

Of course this is not a problem however it turns out that I miss some info from BOM according to the suppressed parts   ...and all these makes sense following the LOD etc.

A potential solution to keep up to date the BOM while you are excluding the needless components is to create 
an i-Assembly.

To keep that simple I turned my current Assembly to an i-Assembly and very successfully I excluded various components and of course I included some others by adding extra ROWS. 

So far So good

Now I want to apply some dimensional boundaries by using i-Logic rules. According to them I want to allow this i-assembly to jump among these different ROWS that meet the right criteria.

Very rough thoughts led me to the following code...

For example...

If Width > 600 Then
iPart.ChangeROW ("..." , "...") 'Row-1'
Else
iPart.ChangeROW ("..." , "...") 'Row-2'
End if

The Problem is that the above code works fine, for a example, in case that I will place an i-part in my assembly... However I am looking to change the row of the actual assembly that as I mentioned before I turned it to an i-assembly

To make this even more clear I want to be able to manipulate my i-assembly with i-Logic rules while this is open in Inv. I don't want to change rows while this is placed as a component or sub-assembly in an another assembly...

View 1 Replies View Related

AutoCAD Inventor :: Change BOM Structure With ILogic?

Jan 8, 2014

I'm using rules to control a part that I made. This part is available in steel and wood. 

But steel = normal and wood is something we have to buy.

I would like to adjust my rule so that my material choice will effect the "Default BOM Structure"

I just can't find the right "code" to start with.

View 8 Replies View Related

AutoCAD Inventor :: Using ILogic To Change An IPart Row?

Oct 25, 2012

I have a sheet metal part that I converted into an iPart and I set up different rows with different sheet metal styles. What I want to do is run an iLogic code to change to a specific row which in turn would change the actual material of that sheet metal part....I've tried the snippet iPart.ChangeRow but cannot get it to run the code. I'm not sure if I'm not doing something right or what...

Inventor 2014, Windows 7, 64 bit

View 9 Replies View Related

AutoCAD Inventor :: Change Hole Type With ILogic

May 21, 2013

I would like to know if it is possible to use iLogic to change the Hole Type from Through to Tapped as conditions dictate.  Is this even possible?  I already have a backup plan but wanted to check out all possibilites before I proceed.  Using Inventor 2012 SP2.

View 1 Replies View Related

AutoCAD Inventor :: Change Part By ILogic In Assembly?

Jul 25, 2012

Before using iLogic, I created lot of iAssembly and iPart. I could change iPart factory member when I need in iAssembly.Now, I want to move everything to iLogic.

how could I change the part by iLogic code?

For example:

I generated "Part1.ipt" and "Part2.ipt",...... (I have hundred of member)

In my assembly, sometimes, I need use Part1.ipt, sometimes I need use Part2.ipt.

Which is the iLogic Code I should to use?

Inventor 2009, WIN XP.
Autodesk Inventor Professional 2013 (64 Bit) SP2
Windows 7 Professional Service Pack 1
Intel(R) Xeon(R) CPU E5645
12.0 GB Memory

View 9 Replies View Related

AutoCAD Inventor :: Change LOD In Derived Part Through ILogic

Jan 27, 2013

I got this code earlier from Curtis_Waguespack, and i would like to add a setting... When i run this rule it Derives the assembly, but LOD is set to Master, i would like it to be set to my own (Configurator) LOD...

I don't seem to be able to find anything in this code, that defines LOD... 

So far im doing ok with the standard ilogic code, but when it´s API or VBA code im lost..  which leads me to this.. i've been searching the forum back and forth to find a code that performs the feature "Shrinkwrap", and somehow everything i have found so far does not work... even the code example in Inventors help menu under programming, Therefore im trying to solve this with Curtis's code as staring point.. 

'set a reference to the assembly component definintion.'this assumes an assembly document is open.Dim oAsmCompDef As AssemblyComponentDefinitionoAsmCompDef = ThisApplication.ActiveDocument.ComponentDefinition 'define the path and file nameDim sPathandName As StringsPathandName = ThisDoc.PathAndFileName(False)

[Code] .......

View 9 Replies View Related

AutoCAD Inventor :: Using ILogic To Change Model Tolerance

Jul 8, 2013

I need to change one dimension using iLogic.  It changes due to the path taken to manufacture the part.  In a nutshell majority of the time the "OD" has a +.004 / .000 tolerance and the model is drawn at the minimum size.  There are cases when the "OD" has a  +.005/-.005 tolerance and is modeled at the nominal size.   I've learned some of the iLogic to make the change I'm after but not all.  I'm having trouble setting ModelValueType to change the model size.

See the code below, for setting +/-.005" 

IV2012

View 2 Replies View Related

AutoCAD Inventor :: ILogic Material Change Failure?

May 23, 2012

The attached part has some bad work features on it, but I don't care about that (easy fix). It also contains a rule that simply changes the material from "P AND O" (pickles & oiled) to "201 S/S", for some reason the faulty work geometery causes this rule to throw an "unspecified error". If you delete the bad work geometry the rule runs fine.

View 2 Replies View Related

AutoCAD Inventor :: Change The Position Of An ILogic InputListBox?

Aug 8, 2012

We have one ilogic rule with different types of User controled boxes. 1x InputListBox 2x InputBoxes Both InputBoxes appears in the center of the screen. The InputListBox appears in the upper left croner of the screen. That's not optimal for the user This problem only occurs when I call the rule via .net program in the User Interface. The Problem does not occur when I load the rule via runRule in the iLogic Rule Browser.

View 2 Replies View Related

AutoCAD Inventor :: Use ILogic To Change Base Quantity?

Nov 9, 2011

Is there a way to control what the Base Quantity is in Document Settings using iLogic.  I want to be able to use a form to change it to a parameter I have created. 

View 6 Replies View Related

AutoCAD Inventor :: ILogic Titleblock Textbox Change

Sep 10, 2013

I am trying to change the titleblock definition of a drawing when I run my custom ilogic code.  Currently (and for the past few years) the drawing name is defined by the drawing properties part number but when I run my code I would like the drawing name to be defined by the model properties part number as shown below:

Currently the textbox for the part number is configured as below:

And I'd like to change it to this:

The code I have to find the part number is as follows:

Dim x = 1 Dim oTxtBox As Inventor.TextBox For Each oTxtBox In oDrawDoc.ActiveSheet.TitleBlock.Definition.Sketch.TextBoxes If oTxtBox.Text = "<PART NUMBER>" Then oStuff =

[Code]....

View 3 Replies View Related

AutoCAD Inventor :: Browser Name Using ILogic Particular Change To The Number

Jul 4, 2012

I want my browser name using iLogic particular change to the part number. I fill in my iproperties, the part number. Then the browser name has to take over the part number.

But i get an error.

doc = ThisDoc.Document
Dim oCC As ComponentOccurrence
For Each oCC In doc.ComponentDefinition.Occurrences
OccName = oCC.Name
oCC.Name = iProperties.Value("Project", "Part Number")
Next

View 4 Replies View Related

AutoCAD Inventor :: Change PL Header On Drawing Via ILogic

Apr 10, 2013

I want to be able to change the header on a PL in a drawing using iLogic.

I'm able to "find" the PL(s) on a drawing but can't seem to figure out how to access the header property My goal to to change the header to show the P/N of the assembly/part it's created from.

My Current code is below:

doc=ThisDrawing.Document
oBOMs=doc.DrawingBOMs

For Each oBOM In oBOMs
MessageBox.Show("Found a PL", "Title")
Next oBom

In between the for/next loop is where I want to access the current BOM and change it's header depending on the related .iam/.ipt.

View 2 Replies View Related

AutoCAD Inventor :: Change Pattern ILogic In Assembly

May 10, 2012

Change pattern ilogic. How do you change the distance and quantity  in an assembly with ilogic?

It is simple in a part but in an assembly the parameters and equations do show.

View 1 Replies View Related

AutoCAD Inventor :: ILogic Rule To Change All Units?

Nov 25, 2012

I am after a rule to change the unit type of all .ipts from cm to mm.

This has to go down to all levels in hierarchy  but only change .ipt files

View 3 Replies View Related

AutoCAD Inventor :: ILogic Change Assembly To Reference

Oct 26, 2011

Is there a way to set an assemblies bill of material setting to reference through iLogic?

View 3 Replies View Related

AutoCAD Inventor :: ILogic To Change Colors Of Parts

Mar 12, 2013

I am looking for a rule that will search assembly down all levels and find .ipts with the material of plywood and when found change all plywoods to color Clear - Light.

View 9 Replies View Related

AutoCAD Inventor :: ILogic Frame Generator Part Change

Oct 21, 2013

I'm slowly getting there with iLogic, so I'm really just looking for the function / call to change one part from Frame Generator, to another part from Frame Generator.

Product Design Suite Premium 2014
Inventor 2014 Professional
Windows 7 Professional 64 bit
Intel Xeon E3-1240 @ 3.4 ghz
Nvidia Quadro 600
8.00 gb RAM

View 2 Replies View Related

AutoCAD Inventor :: Change Patterned Component IProperties Via ILogic

Sep 19, 2012

I'm working on a main assembly. I want to edit the i properties of components within a sub-assembly, this is fine for "RING:1"
 
iProperties.Value("RING:1","Project", "Description")="A79-H020B001"

but I get an error message when i try to edit the iproperties of a patterned component within the sub-assembly.

View 3 Replies View Related

AutoCAD Inventor :: Change Positional Representations In Sub Assembly Using ILogic?

Dec 12, 2012

I'm configuring a band with different supports. Each support is configured with a range; 600-900, 900-1200, 1200-1500 etc. those ranges can be adjust by 50mm and those steps are specified by the pos reps (see attached image).

All the different supports are put in the top assembly and in this assembly I want to switch between the positional representations. I tried to use: 

ThisApplication.ActiveDocument.ComponentDefinition.RepresentationsManager.PositionalRepresentations("MyPosRep").Activate

But it won't work. I guess I have to replace "ComponentDefinition" in one way or another to the component name, but I don't know how.

View 3 Replies View Related

AutoCAD Inventor :: Change BOM Structure Of Component Within Assembly Using ILogic

Nov 22, 2011

I have a wall of frames, if you will, and some frames within this wall are different sizes. When doing the BOM, I want to be able to combine anything that has the same stock number as well as the same cut length. The only way I have thought to do this so far is to cycle through each stock number and if the cut length is the same, I override the quantity of one and change the BOM Structure of the other to "Reference". 

How can I change the BOM Structure to reference without selecting the part or going through the BOM Editor? Is there some VBA code I could utilize? I am striking out by solely using iLogic.

View 2 Replies View Related

AutoCAD Inventor :: Change Browser Node Icon Using ILogic?

Dec 21, 2012

How can I change the default icon that shows up in the browser node in a part file? I found some VB code but can't seem to get it to work with ilogic.

View 7 Replies View Related

AutoCAD Inventor :: ILogic Change Parameter In Any Part That Is Not A Component

Oct 1, 2013

The commented code does not work. I want to be able to open a part and change its size parameters before i open the assembly. this code will run as an external rule in a new empty file. 

If i can do it without opening the part, that is even better. Test can I open a part, change a param, then close part.

Dim fname As String
fname ="C:Workspacemy_progchanF_BB_L.ipt"
Dim pDoc as PartDocument = ThisApplication.Documents.Open(fname,False)
pDoc  = ThisApplication.Documents.Open(fname)

These are just attempts to find a syntax that works. I need the method to change the parameter.

 'param = pDoc.PartComponentDefinition.Parameter.Param("TKNS")
 'pdoc.parameter.Param("TKNS") = 8
pdoc.Save
pdoc.Close

View 4 Replies View Related

AutoCAD Inventor :: ILogic To Change Parts List Style

Feb 8, 2012

Below are 2 rules that run in succession to create and save a parts list from a base view in a drawing.

I am now trying to set the parts list style to a custom style, ideally while creating the list.

Also, I have to manually go into the list to turn off visibility of certain items (based on material), does I can do this with Ilogic?  I ask because these steps precede a rule that automates placing base views of all parts in the parts list.  If I could get the style and visibility right, I could automate the entire process.

Looking for changing such a style with ilogic?

Inventor & Vault Pro 2012
Windows 7, 64bit
Core i7 920@2.67
8GB

CREATE PARTS LIST____
' Set a reference to the drawing document.
' This assumes a drawing document is active.
Dim oDrawDoc As DrawingDocument
oDrawDoc = ThisApplication.ActiveDocument
'Set a reference to the active sheet.
[Code] .....

View 9 Replies View Related

AutoCAD Inventor :: Change Document Units Using ILogic Rules?

Aug 23, 2012

How do I change the document units using iLogic rules.

View 3 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved