AutoCAD Inventor :: ILogic 2013 - Create Yes / No Property Type
Jun 21, 2012
Dim propertyName1 As String = "Mortise"Dim propertyName2 As String = "Cut Length"customPropertySet = ThisDoc.Document.PropertySets.Item("Inventor User Defined Properties")Try prop = customPropertySet.Item(propertyName1) prop = customPropertySet.Item(propertyName2)Catch ' Assume error means not found customPropertySet.Add("", propertyName1) customPropertySet.Add("", propertyName2)End Try'output the custom iproperties and update the fileRuleParametersOutput()InventorVb.DocumentUpdate()'set iProperties 'iProperties.Value("Custom", "Mortise") = ""'update fileiLogicVb.UpdateWhenDone = True
This code creates custom iProperties if the iProperty isn't found. I'd like to add another iProperty called "Resaw" with a Yes/No property type. Is there a way of doing this the way I have things started here?
I got here on in my templates, two types of weight - net and gross. I've changed the main property MASS of each PART to be the GROSS weight, so when i have one assembly i always get the total gross weight.
And when i wanna get the NET, I open the BOM, show the proper column with this net weight and then export do XLS to sum all of then..
Now the doubt is, to get the things easier, is there a way to put some code in the assemblies, that could sum all the properties "X" from each part and sub assembly to get the total net weight ?
I got here on in my templates, two types of weight - net and gross. I've changed the main property MASS of each PART to be the GROSS weight, so when i have one assembly i always get the total gross weight.
And when i wanna get the NET, I open the BOM, show the proper column with this net weight and then export do XLS to sum all of then..
Now the doubt is, to get the things easier, is there a way to put some code in the assemblies, that could sum all the properties "X" from each part and sub assemblie to get the total net weight ?
I would like to set the custom property format for all user paramters from an iLogic code. This is what I've come up with. It runs, but it does not seem to alter the custom property format. What am I doing wrong here?
I have a part number that i want to defined in custom properties.
Then would it be possible to call it out in Ilogic? that way in any drawing doesn't matter where the part number will always be the same for that part when i balloon and the same in the BOM.
Is there a way to get the "view type" of a view using iLogic? for example;
-detail view -section view -exploded view
Or any way to differentiate between the types of views? I'm trying to write a rule that renames all detail and section views in a drawing in Alphabetical order. A,B,C,D..
When using Inventor with Vault, we have a problem when categorizing custom content center parts in Vault. In short, custom content center parts are incorrectly categorized as "Content Center" and automatically released - as there is no property that we can use to identify these files.
I need iLogic code to trigger when custom content center files are created/saved, wich adds the following custom iproperty "IsCustomContentCenter=True".
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.
I am using ilogic in Inventor 2011 to update my iproperties when I save a .dwg file. I am having problems with some custom iProperties I have created that are of the type 'number' and are initially set to 0 (zero). After the iLogic rule has run and the user has entered a numeric value the type of the custom iproperty has changed to 'text'.
The ilogic code I am using is:
If iProperties.Value("Custom", "Nominal ID") = 0 Then iProperties.Value("Custom", "Nominal ID") = InputBox("Enter The Nominal ID (Enter 0 if no value is available)", "Nominal ID", 0) Custom_iProp_Nom_ID = iProperties.Value("Custom", "Nominal ID") End If
I am using Vault 2011 and would like to map this property to a numeric property so I can perform <= and >= searches.
I'm trying to figure out how to create an iLogic rule that would create a Custom iProperties and put in what version of Inventor the file was last updated with.
I want to create a rule that will warn the user when the plate thickness they are using is not standard. I have already created a multivalue parameter for plate thickness, which lists all standard steel plate thickness's and also allows for custom values.
I was hoping I could create a rule that would prompt a dialogue box warning when the user creates a custom value for plate thickness.
I know this can be done, but like I said, Im bloody useless with iLogic and find it hard to come across relevent examples and/or tutorials online.
Is there Any code out there that will allow user to select part file then isolate and create view rep of that part with name of view rep the same as part.
The reason is we have lots of reps that isolate various components and this is very time consuming, I have had a look if there is Any customization because this would be a good user tool,also could work very well on assembly.
I have try for create simple procedure / function in iLogic but can't work.
function LOD (ByVal a as string) as DrawingView ThisApplication.FileManager.GetLastActiveLevelOfDetailRepresentation(a)end function LOD_Assy = LOD(DirName)
I would like to create an new custom ipropertie with ilogic. The reason is the contentcenter, thei haven't custom iproperties. How should the code work:
if propertie "test" is available write the value in the propertie else if propertie test isn't available create prpertie write the value in the propertie end if
How can i check if the propertie is already exists in the file?
How can i create a new custom iPropertie?
The rest of teh code is ready and works fine.
i've faund already some code with VBA but not with "pure" ilogic.
I am trying to create a new sheet in an existing excel file and can not figure out how to do it.
I am trying to export parts lists from multiple drawings to an exisitng excel spreadsheet and I'd like have each on their own sheet. I can do everything but create a sheet. How to do this in iLogic?
Inventor Pro 2013 (PDS Ultimate) Vault Pro 2013 Windows 7 64 Xeon 2.4 Ghz 12GB
I have one particular file which will not allow me to add an iLogic form. When I select "Add Form" it does nothing. This only happens in this one file. I can open other files in the same session and they work fine. I can add iLogic rules to this file but I can't create forms.
I am trying to use a code window plugin on my website, and would like to create a temple for iLogic code. Is there any way to output iLogic code in a format that would work?
I cannot modify any of the existing templates because iLogic requires information as to whether to make some text brown or blue, and it would need some form of output to do that.
[URL]
The instruction page is here: [URL]
I have been manually highlighting or using images, but both have their problems. (cut & paste will lead to a pile of errors with the manual highlighting). I can create the css file, but need some form of output beyond cut & paste to work with.
If something is worked out, it will be added to the program and be available to everyone free (this is a Wordpress plugin).
[URL]
Self built computer with;
Quad core processor 16 gigs ram Raptor Raid main drives 2 x 1TB Caviar Black storage drives local 2 x 1TB Caviar Black storage drives network backup
Main Software; Product Design Suite Premium Windows 7 Home Premium [URL]
Im after programmatically mating 2 components together in an assembly. My stages are as follows:
1)Create New Assembly
2)Add .ipt's
3) One-by-one, mate all the parts together (each part has a plane named "WPStart" and "WPEnd". In each part im after the WPStart being flush mated with the WPEnd of the 2nd part - see image attached. In addition I would like to mate al the XZ planes in each of the parts fluch together and likewize the YZ planes.
Finally, we updated to 2013 Inventor Professional (64 bit).
Now I have some problems when I run the rule which I created in 2009 (32 bit).
First one is:I created a rule which is suppressed. I need run it when I save files. The problem is: after I moved to 2013, and when I puch SAVE button, my rule cannot be run.
Autodesk Inventor Professional 2013 (64 Bit) SP2 Windows 7 Professional Service Pack 1 Intel(R) Xeon(R) CPU E5645 12.0 GB Memory
I have tried to load a custom line type from Autocad 2013 to Inventor 2013, through Edit Laver-->Line type -->Other --> Load, but it doesn't appear in the drop-down list. I have read that previous Inventor releases coudn't work with autocad custom or complex line types. Is it still like that?
I'm attempting to create a model that autmotaically derives ready-to-go drawings. I've gotten pretty far in doing so but have a few issues with regards to dimensioning. As I'm sure you're aware, when the model changes, a dimension to that feature, which has been removed, is also deleted and some those dimensions do not return once the model is changed back.
I have looked into using different view representations, but have found that they do not accommodate feature supression.
Is there a way to program in the dimensioning of a view.
Create center points for of the holes and center lines.
And for a feature note such as "Hole and Thread" dimensioning, when the model expands, the leader and text length do not change and proceed into the view. Is there a way to fix or anchor the text to a certain spot on the drawing, and have the leader length expand and change accordingly to that point.
I have an assembly with parameters named the same as LOD's.
The parameters are set to equal the mass of the corresponding LOD's using ilogic.
If the LOD does not exist, I want to set the mass of the corresponding parameter to a value of zero.
I don't know how to check for the existence of the LOD and I'm not sure I can have three commands in the ELSE section.
Below is an example of what I need using a Parameter and LOD called EXTERNALS as an example.
If EXTERNALS LOD does not exist THEN Parameter("EXTERNALS")=0 ELSE 'activate the EXTERNALS LOD ThisDoc.Document.ComponentDefinition.RepresentationsManager.LevelofDetailRepresentations("EXTERNALS").Activate