Bolted connection don't update after ilogic changes possition of holes

Bolted connection don't update after ilogic changes possition of holes

stamy1
Enthusiast Enthusiast
316 Views
1 Reply
Message 1 of 2

Bolted connection don't update after ilogic changes possition of holes

stamy1
Enthusiast
Enthusiast

if ilogic change the distance between holes in a part the bolted connection don't following the changes so the bolts appears in wrong place. It's a big mesh to manual update all bolted connection in subassembly's.

0 Likes
317 Views
1 Reply
Reply (1)
Message 2 of 2

A.Acheson
Mentor
Mentor

You could try and automate the pressing of the update button exactly as you do manually. Here is the post where I found the below code. I would suggest try this on a test assembly. I find anything with bolt generator still needs to be checked thoroughly in the drawing stage to ensure the holes are set in the right place. 


'This version of the code by Clint Brown, originally posted at https://clintbrown.co.uk/iLogicBolts
'Acknowlegments: Rossano Praderi posted see his post in the forum below
'https://forums.autodesk.com/t5/inventor-customization/bolt-size-with-ilogic/td-p/6232695

On Error Resume Next
Dim oAss As AssemblyDocument = ThisApplication.ActiveEditDocument
Dim bp As BrowserPane = ThisApplication.ActiveDocument.BrowserPanes.ActivePane
Dim node As BrowserNode

For Each node In bp.TopNode.BrowserNodes
    If InStr(1, UCase(node.BrowserNodeDefinition.Label), "BOLTED") > 0 Then 
        oAss.SelectSet.Select(node.NativeObject)
       Call ThisApplication.CommandManager.ControlDefinitions.Item("FDSolveAuto").Execute
	   ThisApplication.StatusBarText = "Success: Bolted Connections updated"
    End If
Next
ThisApplication.StatusBarText = "Bolts updated, system will now set them back to Manual Solve"

For Each node In bp.TopNode.BrowserNodes
    If InStr(1, UCase(node.BrowserNodeDefinition.Label), "BOLTED") > 0 Then 
        oAss.SelectSet.Select(node.NativeObject)
Call ThisApplication.CommandManager.ControlDefinitions.Item("FDSolveManual").Execute
ThisApplication.StatusBarText = "Success: Bolted Connections updated"
End If
Next

ThisApplication.StatusBarText = "Your Bolted Connections have all been Updated"

 

If this solved a problem, please click (accept) as solution.‌‌‌‌
Or if this helped you, please, click (like)‌‌
Regards
Alan
0 Likes