<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Changing Positional Representation Using iLogic in Inventor Programming Forum</title>
    <link>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/6836686#M132698</link>
    <description>&lt;P&gt;&lt;STRONG&gt;That is really good.&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;It gives the running indication - Thanks a lot.&lt;/P&gt;</description>
    <pubDate>Fri, 27 Jan 2017 20:31:32 GMT</pubDate>
    <dc:creator>RoyWickrama_RWEI</dc:creator>
    <dc:date>2017-01-27T20:31:32Z</dc:date>
    <item>
      <title>Changing Positional Representation Using iLogic</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/3754849#M132690</link>
      <description>&lt;P&gt;Can anybody help me what command i neet to use to change between different Positional Representations?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 16 Jan 2013 19:54:58 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/3754849#M132690</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-01-16T19:54:58Z</dc:date>
    </item>
    <item>
      <title>Re: Changing Positional Representation Using iLogic</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/3754964#M132691</link>
      <description>&lt;P&gt;Hi dodrain,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Attached is a sample assembly that has this rule in it.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The rule gets the active&amp;nbsp;Positional rep, then gets all of the&amp;nbsp;Positional rep names and adds them to a list, then presents the list to the user and automatically sets the active Positional rep as the default in the list. Then either sets the selected&amp;nbsp;Positional rep active or creates a new one, based on the user input.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I hope this helps.&lt;BR /&gt;Best of luck to you in all of your Inventor pursuits,&lt;BR /&gt;Curtis&lt;BR /&gt;&lt;A href="http://inventortrenches.blogspot.com" target="_blank"&gt;http://inventortrenches.blogspot.com&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&amp;nbsp;'set a reference to the assembly component definition.&lt;BR /&gt;&amp;nbsp;'This assumes an assembly document is open.&lt;BR /&gt;Dim oAsmCompDef As AssemblyComponentDefinition&lt;BR /&gt;oAsmCompDef = ThisApplication.ActiveDocument.ComponentDefinition&lt;BR /&gt;&lt;BR /&gt;'define pos rep &lt;BR /&gt;Dim oPosRep As PositionalRepresentation&lt;BR /&gt;Dim sPosRep As String&lt;BR /&gt;Dim MyArrayList As New ArrayList&lt;BR /&gt;&lt;BR /&gt;'record the active view rep name&lt;BR /&gt;Dim sActivePosRep as String&lt;BR /&gt;sActivePosRep = oAsmCompDef.RepresentationsManager.ActivePositionalRepresentation.Name&lt;BR /&gt;&lt;BR /&gt;For Each oPosRep In oAsmCompDef.RepresentationsManager.PositionalRepresentations&lt;BR /&gt;MyArrayList.add(oPosRep.Name)&lt;BR /&gt;Next&lt;BR /&gt;&lt;BR /&gt;iArrayList = MyArrayList.Count&lt;BR /&gt;MyArrayList.add("*Add a new Positional Rep*")&lt;BR /&gt;&lt;BR /&gt;sPosRep = InputListBox("Select from the list:", MyArrayList, sActivePosRep, "iLogic", "Positional Reps")&lt;BR /&gt;&lt;BR /&gt;If sPosRep = "*Add a new Positional Rep*" Then&lt;BR /&gt;newPosRep = InputBox("Enter a name:", "iLogic", "New Pos Rep_" &amp;amp; iArrayList)&lt;BR /&gt;newAngle = InputBox("Enter an Angle:", "iLogic", "5")&lt;BR /&gt;'create new pos rep&lt;BR /&gt;oAsmCompDef.RepresentationsManager.PositionalRepresentations.Add(newPosRep)&lt;BR /&gt;myAngle = newAngle&lt;BR /&gt;Else&lt;BR /&gt;'activate the selected pos rep&lt;BR /&gt;oAsmCompDef.RepresentationsManager.PositionalRepresentations.Item(sPosRep).Activate&amp;nbsp;&amp;nbsp; &amp;nbsp;&lt;BR /&gt;End If&lt;BR /&gt;&lt;BR /&gt;'zoom all&lt;BR /&gt;ThisApplication.ActiveView.Fit&lt;BR /&gt;&lt;BR /&gt;
&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 16 Jan 2013 21:48:41 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/3754964#M132691</guid>
      <dc:creator>Curtis_W</dc:creator>
      <dc:date>2013-01-16T21:48:41Z</dc:date>
    </item>
    <item>
      <title>Re: Changing Positional Representation Using iLogic</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/5565068#M132692</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I've got a question about this script, when i enter the same value of the Angle as it is in the master then the value doesn't get a override. Is there a way to force it to give it a override?&lt;/P&gt;&lt;P&gt;So when i change the master value, the Positional Representation stays in the position and doesn't change to.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Bart&lt;/P&gt;</description>
      <pubDate>Tue, 31 Mar 2015 13:55:39 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/5565068#M132692</guid>
      <dc:creator>bartschutte</dc:creator>
      <dc:date>2015-03-31T13:55:39Z</dc:date>
    </item>
    <item>
      <title>Re: Changing Positional Representation Using iLogic</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/6834994#M132693</link>
      <description>&lt;P&gt;Thanks Curtis. Nice example wit the inventor assembly. I used the coding for my purpose. A little more to go in my model - I keep developing using iLogic to maintain data accuracy and ease of modelling.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;With your code for the Design View Representations, I developed the coding for Positional Representations and Level of Detail as well and combined in to a one.&amp;nbsp;With Level of Detail part runs first, t run well&amp;nbsp;as required.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;Sub Main()
Dim oName_PR As String

'set a reference to the assembly component definition.
'This assumes an assembly document is open.
Dim oAsmCompDef As AssemblyComponentDefinition
oAsmCompDef = ThisApplication.ActiveDocument.ComponentDefinition
oAsmCompDef.RepresentationsManager.LevelOfDetailRepresentations.Item("Master").Activate	
'define pos rep 
Dim oLOD As LevelOfDetailRepresentation
Dim oLOD_Rqd As String
Dim oArray_LODs As New ArrayList

'record the active view rep name
Dim oActiveLOD As String
oActiveLOD = oAsmCompDef.RepresentationsManager.ActiveLevelOfDetailRepresentation.Name

For Each oLOD In oAsmCompDef.RepresentationsManager.LevelOfDetailRepresentations
oArray_LODs.add(oLOD.Name)
Next

oAsmCompDef.RepresentationsManager.LevelOfDetailRepresentations.Item("Master").Activate	

iArrayList = oArray_LODs.Count
oLOD_New = "To create new, CLICK!"
oArray_LODs.add(oLOD_New)

oLOD_Rqd = InputListBox("Select PREF from the list:", oArray_LODs, oActiveLOD, "iLogic", "SET Positional Rep. (PREF)")

If oLOD_Rqd = oLOD_New Then
newPosRep = InputBox("Enter a name:", "iLogic", "New Pos Rep_" &amp;amp; iArrayList)
newAngle = InputBox("Enter an Angle:", "iLogic", "5")
'create new pos rep
oAsmCompDef.RepresentationsManager.LevelOfDetailRepresentations.Add(newPosRep)
myAngle = newAngle
Else
'activate the selected pos rep
oAsmCompDef.RepresentationsManager.LevelOfDetailRepresentations.Item(oLOD_Rqd).Activate	
End If

'activate the selected pos rep
oAsmCompDef.RepresentationsManager.LevelOfDetailRepresentations.Item(oLOD_Rqd).Activate	

oPR()
oDefault()
oDVR()
ThisApplication.ActiveView.Fit

End Sub

Sub oPR()
Dim oName_PR As String

'set a reference to the assembly component definition.
'This assumes an assembly document is open.
Dim oAsmCompDef As AssemblyComponentDefinition
oAsmCompDef = ThisApplication.ActiveDocument.ComponentDefinition
oAsmCompDef.RepresentationsManager.PositionalRepresentations.Item("Master").Activate	
'define pos rep 
Dim oPosRep As PositionalRepresentation
Dim oPosRep_Rqd As String
Dim oArray_PosReps As New ArrayList

'record the active view rep name
Dim oActivePosRep As String
oActivePosRep = oAsmCompDef.RepresentationsManager.ActivePositionalRepresentation.Name

For Each oPosRep In oAsmCompDef.RepresentationsManager.PositionalRepresentations
oArray_PosReps.add(oPosRep.Name)
Next

oAsmCompDef.RepresentationsManager.PositionalRepresentations.Item("Master").Activate	

iArrayList = oArray_PosReps.Count
oPosRep_New = "To create new, CLICK!"
oArray_PosReps.add(oPosRep_New)

oPosRep_Rqd = InputListBox("Select PREF from the list:", oArray_PosReps, oActivePosRep, "iLogic", "SET Positional Rep. (PREF)")

If oPosRep_Rqd = oPosRep_New Then
newPosRep = InputBox("Enter a name:", "iLogic", "New Pos Rep_" &amp;amp; iArrayList)
newAngle = InputBox("Enter an Angle:", "iLogic", "5")
'create new pos rep
oAsmCompDef.RepresentationsManager.PositionalRepresentations.Add(newPosRep)
myAngle = newAngle
Else
'activate the selected pos rep
oAsmCompDef.RepresentationsManager.PositionalRepresentations.Item(oPosRep_Rqd).Activate	
End If

'activate the selected pos rep
oAsmCompDef.RepresentationsManager.PositionalRepresentations.Item(oPosRep_Rqd).Activate	

End Sub

Sub oDefault()
Dim doc As AssemblyDocument = ThisDoc.Document
Dim oAsmCompDef As ComponentDefinition
oAsmCompDef = doc.ComponentDefinition
Dim oCompOcc As Inventor.ComponentOccurrence
For Each oCompOcc in oAsmCompDef.Occurrences

If oCompOcc.Visible = True Then
	If oCompOcc.DefinitionDocumentType = kAssemblyDocumentObject Then
	oCompOcc.SetDesignViewRepresentation("Default", True)
	Else
	End If
Else
End If

'oCompOcc.SetDesignViewRepresentation("Default",, True)
On Error Resume Next
Next

End Sub


Sub oDVR()

'get the current assembly
Dim oDoc As AssemblyDocument
oDoc = ThisApplication.ActiveDocument
 
'get AssemblyComponentDefinition
Dim oAsmCompDef As AssemblyComponentDefinition
oAsmCompDef =  oDoc.ComponentDefinition
 
'get Manager of Representations
Dim oViewRepMgr As RepresentationsManager
oViewRepMgr = oAsmCompDef.RepresentationsManager
 

'define new ViewRep - oViewRep_Rqd
'Dim oViewRep As DesignViewRepresentation
Dim oViewRep_Rqd As String
Dim oArray_ViewReps As New ArrayList

'record the active view rep name
Dim oActiveViewRep As String
oActiveViewRep = oAsmCompDef.RepresentationsManager.ActiveDesignViewRepresentation.Name

For Each oViewRep In oAsmCompDef.RepresentationsManager.DesignViewRepresentations
oArray_ViewReps.add(oViewRep.Name)
Next

iArrayList = oArray_ViewReps.Count
oViewRep_New = "To create new, CLICK!"
oArray_ViewReps.add(oViewRep_New)

oViewRep_Rqd = InputListBox("Select PREF from the list:", oArray_ViewReps, oActiveViewRep(2), "iLogic", "SET Design View Rep. (DVR)")

If oViewRep_Rqd = oViewRep_New Then
newViewRep = InputBox("Enter a name:", "iLogic", "New View Rep_" &amp;amp; iArrayList)
'create new pos rep
oAsmCompDef.RepresentationsManager.DesignViewRepresentations.Add(newViewRep)

Else
'activate the selected pos rep
oAsmCompDef.RepresentationsManager.DesignViewRepresentations.Item(oViewRep_Rqd).Activate	
End If

'activate the selected pos rep
oAsmCompDef.RepresentationsManager.DesignViewRepresentations.Item(oViewRep_Rqd).Activate	

End Sub
&lt;/PRE&gt;</description>
      <pubDate>Fri, 27 Jan 2017 07:36:36 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/6834994#M132693</guid>
      <dc:creator>RoyWickrama_RWEI</dc:creator>
      <dc:date>2017-01-27T07:36:36Z</dc:date>
    </item>
    <item>
      <title>Re: Changing Positional Representation Using iLogic</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/6835035#M132694</link>
      <description>&lt;P&gt;Need to add a progress bar to indicate that it is running.&lt;/P&gt;
&lt;P&gt;Need to add:&lt;/P&gt;
&lt;PRE&gt;ThisApplication.CommandManager.ControlDefinitions.Item("AppViewCubeHomeCmd").Execute&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;All suggestions appreciate.&lt;/P&gt;</description>
      <pubDate>Fri, 27 Jan 2017 08:00:01 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/6835035#M132694</guid>
      <dc:creator>RoyWickrama_RWEI</dc:creator>
      <dc:date>2017-01-27T08:00:01Z</dc:date>
    </item>
    <item>
      <title>Re: Changing Positional Representation Using iLogic</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/6835976#M132695</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/2129088"&gt;@RoyWickrama_RWEI&lt;/a&gt;, here is a cleaned up version of your file that uses a couple shared variables to reduce the amount of lines.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Also, is bunched into a class to be able to use shared variables, and for easier portability.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;And finally, from what I have read, you shouldn't need to comment for each line as the line should be easy enough to read if the variables you are using make sense. Comments should only be there to explain "Why" you are doing things a certain way, as the how is discovered by reading the code in it's written language.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;Sub Main()
	Dim oPR As PosRepOptions
	oPR = New PosRepOptions(ThisApplication)
End Sub

Class PosRepOptions
	Shared oAsmCompDef As AssemblyComponentDefinition
	Shared oRepMgr As RepresentationsManager
	
	Sub New(oInvApp As Object)
		oAsmCompDef = oInvApp.ActiveDocument.ComponentDefinition
		oRepMgr = oAsmCompDef.RepresentationsManager
	
		Call oLODR()
		Call oPR()
		Call oDefaultDV()
		Call oDVR()
	
		oInvApp.ActiveView.Fit
	
	End Sub
	
	Sub oLODR()
		oRepMgr.LevelOfDetailRepresentations.Item("Master").Activate	
	
		Dim oLOD As LevelOfDetailRepresentation
		Dim oLOD_Rqd As String
		Dim oArray_LODs As New ArrayList
		
		Dim oActiveLOD As String
	
		oActiveLOD = oRepMgr.ActiveLevelOfDetailRepresentation.Name
	
		For Each oLOD In oRepMgr.LevelOfDetailRepresentations
			oArray_LODs.add(oLOD.Name)
		Next
	
		oRepMgr.LevelOfDetailRepresentations.Item("Master").Activate	
	
		iArrayList = oArray_LODs.Count
		oLOD_New = "To create new, CLICK!"
		oArray_LODs.add(oLOD_New)
	
		oLOD_Rqd = InputListBox("Select LODRep from the list:", oArray_LODs, oActiveLOD, "iLogic", "SET Level of Detail Rep. (LODRep)")
	
		If oLOD_Rqd = oLOD_New Then
			newPosRep = InputBox("Enter a name:", "iLogic", "New LOD Rep_" &amp;amp; iArrayList)
			oRepMgr.LevelOfDetailRepresentations.Add(newPosRep)
		Else
			oRepMgr.LevelOfDetailRepresentations.Item(oLOD_Rqd).Activate	
		End If
	
		oRepMgr.LevelOfDetailRepresentations.Item(oLOD_Rqd).Activate	
	End Sub
	
	Sub oPR()
		oRepMgr.PositionalRepresentations.Item("Master").Activate	
	
		Dim oPosRep As PositionalRepresentation
		Dim oPosRep_Rqd As String
		Dim oArray_PosReps As New ArrayList
		
		Dim oActivePosRep As String
	
		oActivePosRep = oRepMgr.ActivePositionalRepresentation.Name
	
		For Each oPosRep In oRepMgr.PositionalRepresentations
			oArray_PosReps.add(oPosRep.Name)
		Next
	
		oRepMgr.PositionalRepresentations.Item("Master").Activate	
	
		iArrayList = oArray_PosReps.Count
		oPosRep_New = "To create new, CLICK!"
		oArray_PosReps.add(oPosRep_New)
	
		oPosRep_Rqd = InputListBox("Select PRep from the list:", oArray_PosReps, oActivePosRep, "iLogic", "SET Positional Rep. (PRep)")
	
		If oPosRep_Rqd = oPosRep_New Then
			newPosRep = InputBox("Enter a name:", "iLogic", "New Pos Rep_" &amp;amp; iArrayList)
			newAngle = InputBox("Enter an Angle:", "iLogic", "5")
	
			oRepMgr.PositionalRepresentations.Add(newPosRep)
			myAngle = newAngle
		Else
			oRepMgr.PositionalRepresentations.Item(oPosRep_Rqd).Activate	
		End If
	
		oRepMgr.PositionalRepresentations.Item(oPosRep_Rqd).Activate	
	
	End Sub
	
	Sub oDefaultDV()
		On Error Resume Next
	
		Dim oCompOcc As Inventor.ComponentOccurrence
		
		For Each oCompOcc in oAsmCompDef.Occurrences
			If oCompOcc.Visible = True Then
				If oCompOcc.DefinitionDocumentType = kAssemblyDocumentObject Then
					oCompOcc.SetDesignViewRepresentation("Default", True)
				End If
			End If
		
		Next
	End Sub
	
	
	Sub oDVR()
		Dim oViewRep_Rqd As String
		Dim oArray_ViewReps As New ArrayList
	
		Dim oActiveViewRep As String
		oActiveViewRep = oRepMgr.ActiveDesignViewRepresentation.Name
	
		For Each oViewRep In oRepMgr.DesignViewRepresentations
			oArray_ViewReps.add(oViewRep.Name)
		Next
	
		iArrayList = oArray_ViewReps.Count
		oViewRep_New = "To create new, CLICK!"
		oArray_ViewReps.add(oViewRep_New)
	
		oViewRep_Rqd = InputListBox("Select DVRep from the list:", oArray_ViewReps, oActiveViewRep, "iLogic", "SET Design View Rep. (DVRep)")
	
		If oViewRep_Rqd = oViewRep_New Then
			newViewRep = InputBox("Enter a name:", "iLogic", "New View Rep_" &amp;amp; iArrayList)
			oRepMgr.DesignViewRepresentations.Add(newViewRep)
		Else
			oRepMgr.DesignViewRepresentations.Item(oViewRep_Rqd).Activate	
		End If
	
		oRepMgr.DesignViewRepresentations.Item(oViewRep_Rqd).Activate	
	
	End Sub
End Class&lt;/PRE&gt;</description>
      <pubDate>Fri, 27 Jan 2017 15:47:38 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/6835976#M132695</guid>
      <dc:creator>MechMachineMan</dc:creator>
      <dc:date>2017-01-27T15:47:38Z</dc:date>
    </item>
    <item>
      <title>Re: Changing Positional Representation Using iLogic</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/6836011#M132696</link>
      <description>&lt;P&gt;Thanks a lot. I need to improve. I just know a little VB programming - but trying to use iLogic to a fullest extent. Will adapt your coding style.&lt;/P&gt;</description>
      <pubDate>Fri, 27 Jan 2017 16:02:24 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/6836011#M132696</guid>
      <dc:creator>RoyWickrama_RWEI</dc:creator>
      <dc:date>2017-01-27T16:02:24Z</dc:date>
    </item>
    <item>
      <title>Re: Changing Positional Representation Using iLogic</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/6836427#M132697</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/2129088"&gt;@RoyWickrama_RWEI&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;Need to add a progress bar to indicate that it is running.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;All suggestions appreciate.&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Hi rwickrama,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I can provide a progress bar example if you really want it, but I've started just using the status bar for this, as it's generally just as effective and much simpler.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Just add something like this to your For Each loops or somewhere that will update frequently as the code runs, and it will give you an indicator that the code is running.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;ThisApplication.StatusBarText = "Processing... "&lt;BR /&gt;&lt;BR /&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here's an example:&lt;/P&gt;
&lt;PRE&gt;For i = 0 To 30
ThisApplication.StatusBarText = "Processing... " &amp;amp; i
Threading.Thread.Sleep(100)' delay in millisecond
Next
ThisApplication.StatusBarText = "Complete!"
Threading.Thread.Sleep(2000)' delay in millisecond
&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I hope this helps.&lt;BR /&gt;Best of luck to you in all of your Inventor pursuits,&lt;BR /&gt;Curtis&lt;BR /&gt;&lt;A href="http://inventortrenches.blogspot.com" target="_blank"&gt;http://inventortrenches.blogspot.com&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 27 Jan 2017 18:51:14 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/6836427#M132697</guid>
      <dc:creator>Curtis_W</dc:creator>
      <dc:date>2017-01-27T18:51:14Z</dc:date>
    </item>
    <item>
      <title>Re: Changing Positional Representation Using iLogic</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/6836686#M132698</link>
      <description>&lt;P&gt;&lt;STRONG&gt;That is really good.&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;It gives the running indication - Thanks a lot.&lt;/P&gt;</description>
      <pubDate>Fri, 27 Jan 2017 20:31:32 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/6836686#M132698</guid>
      <dc:creator>RoyWickrama_RWEI</dc:creator>
      <dc:date>2017-01-27T20:31:32Z</dc:date>
    </item>
    <item>
      <title>Re: Changing Positional Representation Using iLogic</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/6837129#M132699</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/2129088"&gt;@RoyWickrama_RWEI&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;It gives the running indication - Thanks a lot.&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Hi &lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/2129088"&gt;@RoyWickrama_RWEI&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I might have given the&amp;nbsp;wrong impression with my example.&amp;nbsp;I couldn't tell for sure from your reply, but I don't use that counting code as a progress bar, that was just meant to be a working example. I thought maybe that's the impression I gave.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;What I generally do is more like this example where, as I'm looping through a collection (refDocs in this example) I call the name of each item&amp;nbsp;into the status bar. It could be LOD name, or whatever, here it's the FullFileName of the refDoc.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This way we "flicker" the status bar with some related info that let's the user know something is happening, but generally it flickers too fast to be of any real use other than a "progress" indicator.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I hope this helps.&lt;BR /&gt;Best of luck to you in all of your Inventor pursuits,&lt;BR /&gt;Curtis&lt;BR /&gt;&lt;A href="http://inventortrenches.blogspot.com" target="_blank"&gt;http://inventortrenches.blogspot.com&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;For Each refDoc in refDocs	
	ThisApplication.StatusBarText = "Processing: " &amp;amp; refDoc.FullFileName &amp;amp; " ..."	

	'code to do lots 
        'of fancy 
        'stuff that 
        'takes a long time 
        'here...

Next&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 27 Jan 2017 23:35:39 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/6837129#M132699</guid>
      <dc:creator>Curtis_W</dc:creator>
      <dc:date>2017-01-27T23:35:39Z</dc:date>
    </item>
    <item>
      <title>Re: Changing Positional Representation Using iLogic</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/8100607#M132700</link>
      <description>&lt;P&gt;Is there a way to accomplish this with a subassembly? I would like to change the representation position inside of a subassembly using ilogic??&lt;/P&gt;</description>
      <pubDate>Fri, 29 Jun 2018 13:37:02 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/8100607#M132700</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-06-29T13:37:02Z</dc:date>
    </item>
    <item>
      <title>Re: Changing Positional Representation Using iLogic</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/12039073#M132701</link>
      <description>&lt;P&gt;I really like your rules that you publish.&lt;/P&gt;&lt;P&gt;How do I change this rule to skip the list and all the extras, a simple rule to set model to a named Position representation "Flipped" .&lt;/P&gt;</description>
      <pubDate>Fri, 16 Jun 2023 13:50:55 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/12039073#M132701</guid>
      <dc:creator>Jolanta_Voigt</dc:creator>
      <dc:date>2023-06-16T13:50:55Z</dc:date>
    </item>
    <item>
      <title>Re: Changing Positional Representation Using iLogic</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/12039102#M132702</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/14062764"&gt;@Jolanta_Voigt&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Try this example.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I hope this helps.&lt;BR /&gt;Best of luck to you in all of your Inventor pursuits,&lt;BR /&gt;Curtis&lt;BR /&gt;&lt;A href="http://inventortrenches.blogspot.com" target="_blank"&gt;http://inventortrenches.blogspot.com&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;SPAN&gt;Try&lt;/SPAN&gt;
	&lt;SPAN&gt;ThisDoc&lt;/SPAN&gt;.&lt;SPAN&gt;Document&lt;/SPAN&gt;.&lt;SPAN&gt;ComponentDefinition&lt;/SPAN&gt;. _
	&lt;SPAN&gt;RepresentationsManager&lt;/SPAN&gt;.&lt;SPAN&gt;PositionalRepresentations&lt;/SPAN&gt;.&lt;SPAN&gt;Item&lt;/SPAN&gt; _
	(&lt;SPAN&gt;"Flipped"&lt;/SPAN&gt;).&lt;SPAN&gt;Activate&lt;/SPAN&gt;
&lt;SPAN&gt;Catch&lt;/SPAN&gt;
&lt;SPAN&gt;End&lt;/SPAN&gt; &lt;SPAN&gt;Try&lt;/SPAN&gt;


&lt;SPAN&gt;'zoom all&lt;/SPAN&gt;
&lt;SPAN&gt;ThisApplication&lt;/SPAN&gt;.&lt;SPAN&gt;ActiveView&lt;/SPAN&gt;.&lt;SPAN&gt;Fit&lt;/SPAN&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 16 Jun 2023 14:01:05 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/12039102#M132702</guid>
      <dc:creator>Curtis_W</dc:creator>
      <dc:date>2023-06-16T14:01:05Z</dc:date>
    </item>
    <item>
      <title>Re: Changing Positional Representation Using iLogic</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/12039160#M132703</link>
      <description>I appreciate that, thank you. I needed it to insert into rules I currently have to Simplify and save each iAssebmly member as stp but I needed it saved in the Flipped position.</description>
      <pubDate>Fri, 16 Jun 2023 14:18:19 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/changing-positional-representation-using-ilogic/m-p/12039160#M132703</guid>
      <dc:creator>Jolanta_Voigt</dc:creator>
      <dc:date>2023-06-16T14:18:19Z</dc:date>
    </item>
  </channel>
</rss>

