AutoCAD Inventor :: How To Stop Automatic Update In ILogic While Entering Values In UI
May 19, 2013
I have one problem in ilogic i developed the model using ilogic rules and dimension values updated through the User interface form.
problem is while entering the values in UI, model updates automatically, but I want to stop automatic update and after entering the all the parameters in the UI then click the done button only update the model.
My UI is like this
It's possible.
View 3 Replies
ADVERTISEMENT
Sep 12, 2011
How to make Automatic Update propeties for Flat Pattern Extens. I have write code and setting rules trigerred by event (Before save, Any model Parameter Change) but if some parameter change properties isn't automatic update. So could some one tell me how to solve this problem.
Part with iLogic code is attached
View 9 Replies
View Related
Nov 2, 2011
I need to insert a table on one of my Inventor drawings, however, it will vary in size (Fixed colums, variable number of rows). I have searched the forum and found this snippet of code to add a 2x20 table.
Sub Main()Dim oDrawDoc As DrawingDocumentoDrawDoc = ThisApplication.ActiveDocumentDim oSheet As SheetoSheet = oDrawDoc.ActiveSheet' Set the column titlesDim oTitles() As String = {"Member","Pos. From Datum A"}Dim oPoint As Point2doPoint = ThisApplication.TransientGeometry.CreatePoint2d(1, 28.7)' Create the custom tableDim oCustomTable As CustomTableoCustomTable = oSheet.CustomTables.Add("Infill Spacing", oPoint, 2, 20, oTitles)End Sub
The Problem
I now need to be able to do two things:
1. Delete all custom tables that may be on the drawing ( I may have more than 1 custom table on the drawing)
2. Access the individual rows and colums in a specific table so I can write a variable into them.
I have searched high and low for the API commands, but cant seem to find them.
View 5 Replies
View Related
Nov 26, 2012
Is there an option somewhere to stop Inventor automatically rotating the view when I create or edit a sketch?
View 2 Replies
View Related
Jun 14, 2011
When we insert a Revision Table to a drawing we have the option to update Revision Number property in the drawing. This property is updated whenever we add a Revision Row.
I want Inventor to update the Revision Number property in the model the same way.
If this is not possible, is there a way to automatically map the Revision Number property in the drawing to the Revision Number property in the model?
View 6 Replies
View Related
Feb 15, 2013
About Substitute Shrink wrap parts, it doesn't automatic update when I use UPDATE or even REBUILD ALL inside the LOD with it, even if I don't break the link with the assembly it doesn't update, so I have to go in each assembly with Substitute parts ( with are many in huge projects) and then verify with "Check for updates" in the correct LOD (which in some cases are more than one per assembly). Is there a way to update them direct from the main assembly with rebuild all or something like that ?
View 1 Replies
View Related
Nov 6, 2012
Dont have a before print Event Triggers . I want to make a rule with automatic print with a right sheet size, but in all my try don't work
that is my last one
'Dim oDraw As Document
oDraw = ThisApplication.ActiveDocument
oDrawDoc = ThisApplication.ActiveDocument
oDrgPrintMgr = oDrawDoc.PrintManager
[code]........
View 9 Replies
View Related
Feb 20, 2013
I have an iLogic rule that populates the fields shown below in our title block. The DIM. Values are strings set with H,W,L values. This works well, but I have an additional need to sort these values in ascending order, so the smallest value is first followed by the next largest and finally the largest value. (4.000x5.000x14.000). I haven't had much luck finding any information about how this can be done. I did however come across some code here that someone else was using for a similar feature.
Dim sizes As New List (Of Decimal)sizes.Add(bH)sizes.Add(bW)sizes.Add(bL)sizes.Sort()D1 = sizes(1)D2 = sizes(2)D3 = sizes(3)
This is what I have been attempting, though it does not work. I get the following error "Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index". I'm not sure if my list type is correct (Decimal), but no matter what I choose it fails. The (bH,bW,bL) are the actual block dimensions pulled from the .ipt file. Once sorted I want the values of each position (1),(2),(3) to be assigned to (D1),(D2),(D3) so I can place them in my title block in the correct order.
View 3 Replies
View Related
Dec 5, 2013
i have some parts in my assembly wich are rotatable, i made some 2d drawings of my machine.
when change a position in the assembly it also change in the 2d drawing which is logic.
is there a way i can stop inventor from updating my 2d drawing when i change something in the main assembly?
im using inventor 2013.
View 1 Replies
View Related
Apr 17, 2012
what i am trying to do is create an iLogic rule that if your drawing view scale is set to the following ...
1:1, 1:2, 1:4, 1:8, 1:12, 1:!6, 1:24, 1:32, 1:48, etc. on the view label for that view it will diplay ...
SCALE: 1/2" = 1'-0"
and so on for the rest for the standard scale factors.
i know it will be some sort of a loop and it needs to check all views when ran for any changes.
i have never done any coding for the drawing side of inventor yet only model coding
View 6 Replies
View Related
Nov 13, 2013
I am currently working with fx parameters and iLogic to drive a model and it's corresponding drawing to change based on a single user parameter.
I have managed to get the drawing to update both the scale of the views I need and the size of the sheet with the change in parameter using the following rule:
IfParameter("EB75551.ipt.Rise")<1801Then
ActiveSheet.ChangeSize("A1", MoveBorderItems :=True)
ElseIfParameter("EB75551.ipt.Rise")>1800Then
ActiveSheet.ChangeSize("A2", MoveBorderItems :=True)
EndIf
However when i attempt to use this with the title block using the function:
ActiveSheet.TitleBlock="My Title Block"
in place of the sheet change size it brings up the error message:
Error in rule: Drawing Title Block, in document: Drawing
The parameter is incorrect. (Exception from HRESULT: 0x80070057 (E_INVALIDARG))
I have read elsewhere that this is due to me having prompted entries for the scale and drawn by fields, however when i use the function designed for prompted entries: ActiveSheet.SetTitleBlock("Other Title Block", "promptedEntry1", "promptedEntry2")
It fills in the prompted entry fields from the code and if i change these entries in the "edit field" option they are overwritten when it is updated.
Is there a way have the prompted entries when you open the drawing fill in the "promptedEntry1" field in the rule so that I can use the rule? Or am I going about it the wrong way?
I should point out i'm new to iLogic and no-one in my workplace can use it so each person changing the "promptedEntry1" field to the scale they wish isn't a wise move.
View 2 Replies
View Related
Sep 27, 2011
Is it possible to stop an infinite loop when running an iLogic rule?
View 4 Replies
View Related
Jan 6, 2011
Is there a way to set the colour of a part using the RGB value? (or perhaps the hexdecimal value?)I know I can set colours in iLogic by specifying an existing colour (ex... iProperties.PartColor = "Green")
I want to avoid adding the colour to Inventor as a custom colour, then referencing it in iLogic... The goal is, if a user specifies the finish on this part to be this colour, it will always be that RGB value (our standard in-house paint colour). I don't want to add it to the Inventor 'colors' design data... when we upgrade to the next version of Inventor, it's one more item we have to remember to carry over!.
View 5 Replies
View Related
Jul 2, 2012
Is it possible to add a stop or cancel button onto ilogic code?
I have code that looks into all .ipts with a certain material type,that works great but if we run by accident there is no way of stopping code until it finishes .
View 3 Replies
View Related
Mar 6, 2012
Ok what I'm tring to do is have a spreadsheet that has a list of prices in it that we could modify if needed for all these parts i'm making. Best way is to have the spreadsheet obviously external of the file.Though now I do not know how to do this in iLogic.And example of what I'm trying to do is, with 3 parameters.
A, B, and P
Value "A" and Value "B", these are just read items which when combined will give Value "P" to be imported into the Part file. So need A & B to be read and give the row number for P to be imported.
View 3 Replies
View Related
Oct 29, 2012
Macro for writing the sheetmetal Extents width and length to the custom properties. I need to get these values into the part parameters so that they can be used in the BOM.
I can get this to work if I manually create the "SM_Length" user parameter, but how do I make the iLogic CREATE the parameters if they do not already exist? I think it would be something added below the "Catch..." just cant seem to figure out what it needs to be.
'look for custom iproperty and try to set it
Try
iProperties.Value("Custom", sExtLength)=Round(SheetMetal.FlatExtentsLength, iRoundValue)
Parameter("SM_Length")=Round(SheetMetal.FlatExtentsLength,4)
Catch
' assume error means not found and create it
customPropertySet.Add(Round(SheetMetal.FlatExtentsLength,iRoundValue), sExtLength)
EndTry
View 9 Replies
View Related
Dec 11, 2013
I have been attempting to automate some prompted entry (PE) values using iLogic and the SetPromptResultText command.
The command works on the customer-supplied template I have if I create a new PE called <DELETEME> - my code also works on this new PE even if I delete the "<" & ">" from either end of the string so it becomes "DELETEME".
The command doesn't work on the customer supplied fields of "PURPOSE OF ISSUE" & "PROJECT REF No" but if I add < & > to either end (so they become "<PROJECT REF No>" & "<PURPOSE OF ISSUE>" respectively) and modify my code to look for that instead, lo and behold it works.
why it works with the "<" & ">" on the ends of the string but not without?
My guess is that the "<" & ">" allow the PE to have spaces and without it Inventor 2013 throws the dummy in the dirt and refuses to play nice! - Just tested that theory and it's clearly cobblers.
Here's the sub-routine I wrote (with the working "<" & ">" still in place):
Sub UpdatePromptedEntries(oDoc As DrawingDocument)'assumes the oDoc is activatedDim oPromptEntryDim actSheet As Sheet = ThisApplication.ActiveDocument.ActiveSheet'For Each oSheet In ThisApplication.ActiveDocument.SheetsFor Each oSheet In
[code]........
View 4 Replies
View Related
Oct 12, 2011
Currently I am using I-logic and a form. I have an assembly that I am pushing a volume from a part to the main assembly. The volume updates in the part fine. The issue is with the form is not updating when the file parameter updates. If I exit the form and run the rule manually then the form updates. how to update the form at the same time?
View 1 Replies
View Related
Sep 13, 2013
I´m having a bit of an issue with a form.
I have a global form which is exactly made for a specific assembly for configuration of this very assembly. To make things easier for the user I call another external rule which only opens exactly this assembly.
Now when the user opens the form the assembly is not open and obviously can´t reference the used parameters.
Even after loading the assembly the parameters are not available, which results in something like this:
So this is a really simple question, is there a way to update a form so that it rereads the parameters from the assembly?
What I tried is using iLogicForm.CloseGlobal("Name of form") to no availability and then open it again with iLogicForm.ShowGlobal("Name of form").
But I couldn´t find any further info on the iLogicForm Commands.
View 3 Replies
View Related
Dec 21, 2011
I am after a way of accessing the update styles on dwg so that I can run with rule below as most of our drawing stds have changed and old dwgs need updating the work flow is as follows.
I need to access manage tab then update styles,then yes to all,OKUpdate all sheetsfind all parts list within all sheet and then annotate , style on format tab and then select Parts list - this will change all my old parts list to current style definition.Either run at begining of code below or run as seperate code
On Error Resume NextDim oDrawDoc As DrawingDocument oDrawDoc = ThisApplication.ActiveDocumentDim Sheet As Inventor.SheetDim Cursheet As String Cursheet = oDrawDoc.ActiveSheet.Name For Each oSheet In oDrawDoc.Sheets oSheet.ActivateDim oPartsList As PartsList oPartsList = oDrawDoc.ActiveSheet.PartsLists.Item(1)If Not oPartsList Is Nothing Then Resume Next'Call oPartsList.Sort("ITEM")Call oPartsList.Sort("PART NUMBER", 1, "DESCRIPTION", 1, "QTY", 1)iLogicVb.UpdateWhenDone = TrueActiveSheet = ThisDrawing.Sheet("Sheet:1")ThisApplication.ActiveView.FitEnd If Next
View 4 Replies
View Related
Aug 17, 2012
I am trying to put an immediate update box on my form in ilogic. I want to be able to change parameters on my form without updating the model. There is this option in the parameters window but not in the form. How can I accomplish this?
View 1 Replies
View Related
Jul 28, 2012
I am new to the ilogic. I am wanting to use ilogic to update some prints as needed.
I need to create and external rule to:
1) migrate the drawing to the lastest inventor version (2012),
2) copy all drawing resources (borders, title blocks, and sketched symbols) from a template file (.idw),
3) replace the title block and border with specified block and border.
View 9 Replies
View Related
Mar 29, 2012
I have an ilogic assembly that I change to different widths. And I want ilogic to put the part number into the title block according to the size of the assembly.
What I have works but won't update on its own. I have to open the ilogic rule and close it, then open the i properties of the idw and close before it will update.
View 3 Replies
View Related
May 2, 2013
I have an assembly which is made with a sub assembly. The sub assembly has iLogic code that both resizes it's parts and suppresses parts that arn't needed after a change in length.
View 5 Replies
View Related
Oct 8, 2013
I made iLogic for assembly and drawing, now i want to update drawing template parameters thru ilogic, as i already linked Fx(parameters) & iProperties to Template, but for updating template i need to close file and open again that file,
currently m using this method.
What is the solution for updating drawing template (like Model Description, Drawing no.).
View 3 Replies
View Related
Aug 9, 2012
Is there any way to force an update of mass property values of a component from within an iLogic routine?
I am trying to produce a calibration chart showing the volumes of an irregular shaped object by taking incremental slices off the component and accessing the "volume" of the remaining portion, then writing the the results to an external file - All from within a "For - Next" loop.
The main routine works O.K. but the resultant chart only shows the original starting volume for each slice instead of the required reducing volumes.
I am a novice with iLogic and can only assume that I must somehow "update" the mass properties of the sliced object before reading its new volume on each pass.
View 7 Replies
View Related
Dec 28, 2013
Is it possible to update an existing User Parameter. While I can only delete-create a new. In this case the connection is lost with BOMQuantity.
View 5 Replies
View Related
Aug 4, 2013
The rule iterates through an assembly looking for parameters. If it finds them it 'pushes' the value down from the top level Assembly into the sub-components.
It works well, but each component updates dynamically as the parameter value is changed. This looks a bit jerky and weird.Is there any way to write the script so the the updates all happen at once at the end?
' set a reference to the assembly component definintion.' This assumes an assembly document is open.Dim oAsmCompDef As AssemblyComponentDefinitionoAsmCompDef = ThisApplication.ActiveDocument.ComponentDefinition'Iterate through all of the occurrencesDim oOccurrence As ComponentOccurrenceFor Each oOccurrence In oAsmCompDef.Occurrences'check for and skip virtual components'(in case a virtual.
[code]...
View 7 Replies
View Related
Jul 10, 2013
as a part of automating manufacturing drawings, am trying to include ilogic code in the drawing , that would accept values from the user and store it as "user parameters" and make corresponding changes in the inventor drawing file.So, to replicate my issue on a smaller scale, i had created 2 parts and created an assembly out of these 2 parts. I used the assembly in my drawing.
In the Drawing i created a user parameter .. say "external_param". I am opening the drawing and changing the value of the user parameter through the (Fx) parameter table.
doc = ThisDoc.DocumentIf external_param >= 50 And external_param <= 99 ThenParameter("block_1.ipt.d0") = 15 'change the length of the blockParameter("block_1.ipt.d14") = 3 'change the number of holes in the blockElseIf external_param >= 100 And external_param <= 199 ThenParameter("block_1.ipt.d0") = 40Parameter("block_1.ipt.d14") = 5ElseIf external_param >= 200 And external_param <= 299 ThenParameter("block_1.ipt.d0") = 80Parameter("block_1.ipt.d14") = 6ElseIf external_param >= 300 And external_param <= 399 ThenParameter("block_1.ipt.d0") = 160Parameter("block_1.ipt.d14") = 9End IfRuleParametersOutput()iLogicVb.UpdateWhenDone = True'InventorVb.DocumentUpdate()
As you can see, i have commented out InventorVb.DocumentUpdate() , im not quite sure what would accomplish the update and save of the assembly document in the background (without prompting for a save/update). I have also tried thisDoc.Save and thisdoc.update. Using these 2 commands along with the InventorVb.DocumentUpdate() or iLogicVb.UpdateWhenDone caused Inventor to Crash.
View 4 Replies
View Related
Nov 12, 2012
The right click context menu on the top level assembly (on the model tree in Inventor) has the option of 'Open Drawing'.
Is there a way to do that via iLogic? Unfortunately I can't figure it out if there is. I would like to open and update the relevant drawing.
Also have tried it the other way around, that is to run my rues in the assembly from the drawing since the drawing is the parent. But I am not sure how to reference the assembly.
View 1 Replies
View Related
Jun 4, 2013
I'm running an iLogic based model where I have a technical housing with 2 cover parts on top.
The first cover part is the basic part.
I use iLogic to assign a RAL-color to several parts in the assembly, also to that cover. The color is assigned to several features of the cover part.
The second cover part is almost identical to the first one.
So my first feature in the second cover part is a derived part of the 1st cover. I derived all the bodies.
When I'm in my assembly and I pick a RAL-color in my created customization form, the RAL-color only changes in the 1st cover part (the original), but it doesn't change in the second cover part, the derived body.
But....
when I manually open the 2nd cover part, and I right click on the derived feature and click on 'Edit Derived Part' ; the new color shows up immediately!
So, my question is if there is a rule for iLogic to update the color automatically?
View 5 Replies
View Related