<?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 iProperties with iLogic in Inventor Programming - iLogic, Macros, AddIns &amp; Apprentice</title>
    <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/changing-iproperties-with-ilogic/m-p/12357017#M159970</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/8021187"&gt;@Daan_M&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;As&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/7812054"&gt;@WCrihfield&lt;/a&gt;&amp;nbsp;indicated we can use the API calls to get the property set, and the property, since you are working with the application's referenced documents, and not the referenced documents of an assembly.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here is an update to my previous 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" rel="noopener"&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;Dim&lt;/SPAN&gt; &lt;SPAN&gt;rDocs&lt;/SPAN&gt; &lt;SPAN&gt;As&lt;/SPAN&gt; &lt;SPAN&gt;Documents&lt;/SPAN&gt; = &lt;SPAN&gt;ThisApplication&lt;/SPAN&gt;.&lt;SPAN&gt;Documents&lt;/SPAN&gt;
&lt;SPAN&gt;For&lt;/SPAN&gt; &lt;SPAN&gt;Each&lt;/SPAN&gt; &lt;SPAN&gt;rDoc&lt;/SPAN&gt; &lt;SPAN&gt;As&lt;/SPAN&gt; &lt;SPAN&gt;Document&lt;/SPAN&gt; &lt;SPAN&gt;In&lt;/SPAN&gt; &lt;SPAN&gt;rDocs&lt;/SPAN&gt;
	&lt;SPAN&gt;oDoc&lt;/SPAN&gt; = &lt;SPAN&gt;ThisApplication&lt;/SPAN&gt;.&lt;SPAN&gt;Documents&lt;/SPAN&gt;.&lt;SPAN&gt;Open&lt;/SPAN&gt;(&lt;SPAN&gt;rDoc&lt;/SPAN&gt;.&lt;SPAN&gt;FullFileName&lt;/SPAN&gt;, &lt;SPAN&gt;True&lt;/SPAN&gt;)
	&lt;SPAN&gt;oDoc&lt;/SPAN&gt;.&lt;SPAN&gt;Activate&lt;/SPAN&gt;
	
	&lt;SPAN&gt;'get the property set&lt;/SPAN&gt;
	&lt;SPAN&gt;Dim&lt;/SPAN&gt; &lt;SPAN&gt;oDTPropSet&lt;/SPAN&gt; &lt;SPAN&gt;As&lt;/SPAN&gt; &lt;SPAN&gt;PropertySet&lt;/SPAN&gt;
	&lt;SPAN&gt;oDTPropSet&lt;/SPAN&gt; = &lt;SPAN&gt;oDoc&lt;/SPAN&gt;.&lt;SPAN&gt;PropertySets&lt;/SPAN&gt;.&lt;SPAN&gt;Item&lt;/SPAN&gt;(&lt;SPAN&gt;"Design Tracking Properties"&lt;/SPAN&gt;)	
	
	&lt;SPAN&gt;'get the property by name&lt;/SPAN&gt;
	&lt;SPAN&gt;Dim&lt;/SPAN&gt; &lt;SPAN&gt;oProperty&lt;/SPAN&gt; &lt;SPAN&gt;As&lt;/SPAN&gt; &lt;SPAN&gt;Inventor&lt;/SPAN&gt;.&lt;SPAN&gt;Property&lt;/SPAN&gt;
	&lt;SPAN&gt;oProperty&lt;/SPAN&gt; = &lt;SPAN&gt;oDTPropSet&lt;/SPAN&gt;.&lt;SPAN&gt;Item&lt;/SPAN&gt;(&lt;SPAN&gt;"Description"&lt;/SPAN&gt;)

	&lt;SPAN&gt;'set the value&lt;/SPAN&gt;
	 &lt;SPAN&gt;oProperty&lt;/SPAN&gt;.&lt;SPAN&gt;Value&lt;/SPAN&gt; = &lt;SPAN&gt;"Hello World"&lt;/SPAN&gt;

	&lt;SPAN&gt;MsgBox&lt;/SPAN&gt;(&lt;SPAN&gt;oDoc&lt;/SPAN&gt;.&lt;SPAN&gt;DisplayName&lt;/SPAN&gt; &amp;amp; &lt;SPAN&gt;vbLf&lt;/SPAN&gt; &amp;amp; &lt;SPAN&gt;oProperty&lt;/SPAN&gt;.&lt;SPAN&gt;DisplayName&lt;/SPAN&gt; &amp;amp; &lt;SPAN&gt;" = "&lt;/SPAN&gt; &amp;amp; &lt;SPAN&gt;oProperty&lt;/SPAN&gt;.&lt;SPAN&gt;Value&lt;/SPAN&gt;)	

	&lt;SPAN&gt;oDoc&lt;/SPAN&gt;.&lt;SPAN&gt;Save&lt;/SPAN&gt;()
	&lt;SPAN&gt;'oDoc.Close&lt;/SPAN&gt;
&lt;SPAN&gt;Next&lt;/SPAN&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 06 Nov 2023 14:28:35 GMT</pubDate>
    <dc:creator>Curtis_Waguespack</dc:creator>
    <dc:date>2023-11-06T14:28:35Z</dc:date>
    <item>
      <title>Changing iProperties with iLogic</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/changing-iproperties-with-ilogic/m-p/12352311#M159894</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm making a code that allows me to fill existing and create new custom iProperties in batches of partfiles, this infomation comes from an Excel file. Unfortunatly the code does everything correctly except changing the actual properties&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The code gives the correct iProperty types, names and values (line 52);&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Daan_M_0-1699025269053.png" style="width: 300px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1288121i11A1F86B491A7F09/image-size/small?v=v2&amp;amp;px=200" role="button" title="Daan_M_0-1699025269053.png" alt="Daan_M_0-1699025269053.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;But the value of the properties do not change when it runs line 54, no errors occur either.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My code (not all of it is important, i think the problem lies in line 54);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="visual-basic"&gt;Imports System.Windows.Forms
Sub main
	
Dim rDocs As Documents = ThisApplication.Documents

Dim oFD As Inventor.FileDialog = Nothing
InventorVb.Application.CreateFileDialog(oFD)
oFD.InitialDirectory = oOrigRefName
oFD.Filter = "Excel file (*.xlsx)|*.xlsx|"
oFD.CancelError = True
On Error Resume Next
oFD.ShowOpen()
If Err.Number &amp;lt;&amp;gt; 0 Then
Return

ElseIf oFD.FileName &amp;lt;&amp;gt; "" Then
selectedfile = oFD.FileName
End If

Dim oExcel As String = selectedfile

Dim i As Integer = 3

Dim PartFileLoc As String = GoExcel.CellValue(oExcel, "Blad1", "A" &amp;amp; i)

If PartFileLoc = "" Then
	MsgBox("Geen PartFileLoc gevonden in cell: A" &amp;amp; i)
Exit Sub
End If

Do While PartFileLoc &amp;lt;&amp;gt; ""

Dim oPartDoc As PartDocument = rDocs.Open(PartFileLoc, True)
oPartDoc.Activate
Dim n As Integer
Dim nRow As Integer = 2

For n = 1 To 26
	oLetter = Mid("ABCDEFGHIJKLMNOPQRSTUVWXYZ", n, 1)
	oCellAddress = oLetter &amp;amp; nRow
	oCellValue = GoExcel.CellValue(oCellAddress)
	GoExcel.TitleRow = nRow
	oColumnName = GoExcel.CellValue(oLetter &amp;amp; nRow)

If oColumnName &amp;lt;&amp;gt; ""

Dim oProperty As String = oColumnName
Dim oPropertyType As String = GoExcel.CellValue(oLetter &amp;amp; 1)
Dim oSetValue As String = GoExcel.CellValue(oExcel, "Blad1", oLetter &amp;amp; i)
	
	MsgBox(oPartDoc.DisplayName)
	MsgBox(oPropertyType &amp;amp; " &amp;amp; " &amp;amp; oProperty &amp;amp; " = " &amp;amp; oSetValue)
	
iProperties.Value(oPropertyType, oProperty) = oSetValue

End If
Next

i = i + 1
PartFileLoc = GoExcel.CellValue("A" &amp;amp; i)
oPartDoc.Save()
'oPartDoc.Close
Loop
End Sub&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What am i doing wrong?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;have a good weekend in advance&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 03 Nov 2023 15:44:49 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/changing-iproperties-with-ilogic/m-p/12352311#M159894</guid>
      <dc:creator>Daan_M</dc:creator>
      <dc:date>2023-11-03T15:44:49Z</dc:date>
    </item>
    <item>
      <title>Re: Changing iProperties with iLogic</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/changing-iproperties-with-ilogic/m-p/12352378#M159895</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/8021187"&gt;@Daan_M&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I think the rule as written is running on all the documents that are referenced by other open documents in Inventor. I'm not sure if that's what you intend or not, it might be.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In any case, I think you just want to change line 54 ( or at least line 54 it is in your post) from :&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="visual-basic"&gt;iProperties.Value(oPropertyType, oProperty) = oSetValue&lt;/LI-CODE&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;LI-CODE lang="visual-basic"&gt;iProperties.Value(oPartDoc.fullfilename, oPropertyType, oProperty) = oSetValue&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;As you had it, it was changing the property in the document from which the rule was run.&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" rel="noopener"&gt;http://inventortrenches.blogspot.com&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 03 Nov 2023 16:15:13 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/changing-iproperties-with-ilogic/m-p/12352378#M159895</guid>
      <dc:creator>Curtis_Waguespack</dc:creator>
      <dc:date>2023-11-03T16:15:13Z</dc:date>
    </item>
    <item>
      <title>Re: Changing iProperties with iLogic</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/changing-iproperties-with-ilogic/m-p/12352415#M159899</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/105031"&gt;@Curtis_Waguespack&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;That's correct, i only want to run the property change on oPartDoc.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Unfortunatly i also tested the line without succes&lt;/P&gt;&lt;LI-CODE lang="visual-basic"&gt;iProperties.Value(oPartDoc.fullfilename, oPropertyType, oProperty) = oSetValue&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It opens the document, gives correct properties and value, but it remains empty;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Daan_M_0-1699028089073.png" style="width: 600px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1288146i125DD88FE67D5E17/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Daan_M_0-1699028089073.png" alt="Daan_M_0-1699028089073.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 03 Nov 2023 16:15:20 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/changing-iproperties-with-ilogic/m-p/12352415#M159899</guid>
      <dc:creator>Daan_M</dc:creator>
      <dc:date>2023-11-03T16:15:20Z</dc:date>
    </item>
    <item>
      <title>Re: Changing iProperties with iLogic</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/changing-iproperties-with-ilogic/m-p/12352467#M159903</link>
      <description>&lt;P&gt;I don't think FullFileName works for the first (of 3) inputs in the iProperties.Value() snippet.&amp;nbsp; It will usually only accept the Document.DisplayName there.&amp;nbsp; And even that is finicky, because sometimes that includes the file extension, and sometimes it does not.&amp;nbsp; And when using the iProperties.Value snippet, it can only reach stuff that is within the ActiveDocument's AllReferencedDocuments collection.&lt;/P&gt;
&lt;P&gt;You might be able to use the new:&lt;/P&gt;
&lt;LI-CODE lang="general"&gt;SOP = StandardObjectFactory.Create(oDoc)
SOP.iProperties.Value()&lt;/LI-CODE&gt;
&lt;P&gt;tools also, to make sure that the iProperties.Value snippet is working with the Document you input into that first line.&lt;/P&gt;</description>
      <pubDate>Fri, 03 Nov 2023 16:38:33 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/changing-iproperties-with-ilogic/m-p/12352467#M159903</guid>
      <dc:creator>WCrihfield</dc:creator>
      <dc:date>2023-11-03T16:38:33Z</dc:date>
    </item>
    <item>
      <title>Re: Changing iProperties with iLogic</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/changing-iproperties-with-ilogic/m-p/12352505#M159904</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/8021187"&gt;@Daan_M&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Well, that's what I get for replying without testing my answer...&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/7812054"&gt;@WCrihfield&lt;/a&gt;&amp;nbsp;is correct, we need to use display name here.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I don't have your Excel data, but this stripped-down version of your rule works.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;SPAN&gt;Dim&lt;/SPAN&gt; &lt;SPAN&gt;oDoc&lt;/SPAN&gt; &lt;SPAN&gt;As&lt;/SPAN&gt; &lt;SPAN&gt;AssemblyDocument&lt;/SPAN&gt; = &lt;SPAN&gt;ThisApplication&lt;/SPAN&gt;.&lt;SPAN&gt;ActiveDocument&lt;/SPAN&gt;
&lt;SPAN&gt;For&lt;/SPAN&gt; &lt;SPAN&gt;Each&lt;/SPAN&gt; &lt;SPAN&gt;rDoc&lt;/SPAN&gt; &lt;SPAN&gt;As&lt;/SPAN&gt; &lt;SPAN&gt;Document&lt;/SPAN&gt; &lt;SPAN&gt;In&lt;/SPAN&gt; &lt;SPAN&gt;oDoc&lt;/SPAN&gt;.&lt;SPAN&gt;AllReferencedDocuments&lt;/SPAN&gt;
	&lt;SPAN&gt;oPartDoc&lt;/SPAN&gt; = &lt;SPAN&gt;ThisApplication&lt;/SPAN&gt;.&lt;SPAN&gt;Documents&lt;/SPAN&gt;.&lt;SPAN&gt;Open&lt;/SPAN&gt;(&lt;SPAN&gt;rDoc&lt;/SPAN&gt;.&lt;SPAN&gt;FullFileName&lt;/SPAN&gt;, &lt;SPAN&gt;True&lt;/SPAN&gt;)
	&lt;SPAN&gt;oPartDoc&lt;/SPAN&gt;.&lt;SPAN&gt;Activate&lt;/SPAN&gt;

	&lt;SPAN&gt;Dim&lt;/SPAN&gt; &lt;SPAN&gt;oProperty&lt;/SPAN&gt; &lt;SPAN&gt;As&lt;/SPAN&gt; &lt;SPAN&gt;String&lt;/SPAN&gt; = &lt;SPAN&gt;"Description"&lt;/SPAN&gt;
	&lt;SPAN&gt;Dim&lt;/SPAN&gt; &lt;SPAN&gt;oSetValue&lt;/SPAN&gt; &lt;SPAN&gt;As&lt;/SPAN&gt; &lt;SPAN&gt;String&lt;/SPAN&gt; = &lt;SPAN&gt;"Hello World"&lt;/SPAN&gt;

	&lt;SPAN&gt;MsgBox&lt;/SPAN&gt;(&lt;SPAN&gt;oPartDoc&lt;/SPAN&gt;.&lt;SPAN&gt;DisplayName&lt;/SPAN&gt;)
	&lt;SPAN&gt;MsgBox&lt;/SPAN&gt;(&lt;SPAN&gt;oProperty&lt;/SPAN&gt; &amp;amp; &lt;SPAN&gt;" = "&lt;/SPAN&gt; &amp;amp; &lt;SPAN&gt;oSetValue&lt;/SPAN&gt;)

	&lt;SPAN&gt;iProperties&lt;/SPAN&gt;.&lt;SPAN&gt;Value&lt;/SPAN&gt;(&lt;SPAN&gt;oPartDoc&lt;/SPAN&gt;.&lt;SPAN&gt;displayname&lt;/SPAN&gt;, &lt;SPAN&gt;"Project"&lt;/SPAN&gt;, &lt;SPAN&gt;oProperty&lt;/SPAN&gt;) = &lt;SPAN&gt;oSetValue&lt;/SPAN&gt;

	&lt;SPAN&gt;oPartDoc&lt;/SPAN&gt;.&lt;SPAN&gt;Save&lt;/SPAN&gt;()
	&lt;SPAN&gt;'oPartDoc.Close&lt;/SPAN&gt;
&lt;SPAN&gt;Next&lt;/SPAN&gt;
&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 03 Nov 2023 18:51:18 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/changing-iproperties-with-ilogic/m-p/12352505#M159904</guid>
      <dc:creator>Curtis_Waguespack</dc:creator>
      <dc:date>2023-11-03T18:51:18Z</dc:date>
    </item>
    <item>
      <title>Re: Changing iProperties with iLogic</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/changing-iproperties-with-ilogic/m-p/12356290#M159958</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/7812054"&gt;@WCrihfield&lt;/a&gt;&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/105031"&gt;@Curtis_Waguespack&lt;/a&gt;&amp;nbsp;Thank you answering.&lt;/P&gt;&lt;P&gt;As i understand it, in order to use the 'iProperties.Value()' snippet i need:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;To use the 'Document.DisplayName'&lt;/LI&gt;&lt;LI&gt;To have the partdocument be present in the referenced documents of the assembly i'm running my rule from&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;Point 2 remains a problem for me because there is no referenced documents present in my assembly file, the assembly file is simply an empty document with various iLogic codes i use.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;How would i get oPartDoc to be referenced document of my assembly file, inside the code i already made?&lt;/P&gt;&lt;P&gt;Because the solution&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/105031"&gt;@Curtis_Waguespack&lt;/a&gt;&amp;nbsp;offered already assumed that there's referenced documents present in my assembly (if i'm not wrong).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My Code;&lt;/P&gt;&lt;LI-CODE lang="visual-basic"&gt;Imports System.Windows.Forms
Sub main

Dim oDoc As AssemblyDocument = ThisApplication.ActiveDocument

Dim oFD As Inventor.FileDialog = Nothing
InventorVb.Application.CreateFileDialog(oFD)
oFD.InitialDirectory = oOrigRefName
oFD.Filter = "Excel file (*.xlsx)|*.xlsx|"
oFD.CancelError = True
On Error Resume Next
oFD.ShowOpen()
If Err.Number &amp;lt;&amp;gt; 0 Then
Return

ElseIf oFD.FileName &amp;lt;&amp;gt; "" Then
selectedfile = oFD.FileName
End If

Dim oExcel As String = selectedfile

Dim i As Integer = 3

Dim PartFileLoc As String = GoExcel.CellValue(oExcel, "Blad1", "A" &amp;amp; i)

If PartFileLoc = "" Then
	MsgBox("Geen PartFileLoc gevonden in cell: A" &amp;amp; i)
Exit Sub
End If

Do While PartFileLoc &amp;lt;&amp;gt; ""

Dim oPartDoc As PartDocument = ThisApplication.Documents.Open(PartFileLoc, True)
oPartDoc.Activate

For Each rDoc As Document In oDoc.AllReferencedDocuments
msgBox(rDoc.FullDocumentName)
Next

Dim n As Integer
Dim nRow As Integer = 2

For n = 1 To 26
	oLetter = Mid("ABCDEFGHIJKLMNOPQRSTUVWXYZ", n, 1)
	oCellAddress = oLetter &amp;amp; nRow
	oCellValue = GoExcel.CellValue(oCellAddress)
	GoExcel.TitleRow = nRow
	oColumnName = GoExcel.CellValue(oLetter &amp;amp; nRow)

If oColumnName &amp;lt;&amp;gt; ""

Dim oProperty As String = oColumnName
Dim oPropertyType As String = GoExcel.CellValue(oLetter &amp;amp; 1)
Dim oSetValue As String = GoExcel.CellValue(oExcel, "Blad1", oLetter &amp;amp; i)
	
iProperties.Value(oPartDoc.DisplayName, oPropertyType, oProperty) = oSetValue

End If
Next

i = i + 1
PartFileLoc = GoExcel.CellValue("A" &amp;amp; i)
oPartDoc.Save()
'oPartDoc.Close
Loop
End Sub&lt;/LI-CODE&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;</description>
      <pubDate>Mon, 06 Nov 2023 08:59:10 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/changing-iproperties-with-ilogic/m-p/12356290#M159958</guid>
      <dc:creator>Daan_M</dc:creator>
      <dc:date>2023-11-06T08:59:10Z</dc:date>
    </item>
    <item>
      <title>Re: Changing iProperties with iLogic</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/changing-iproperties-with-ilogic/m-p/12356873#M159966</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/8021187"&gt;@Daan_M&lt;/a&gt;.&amp;nbsp; If your main concern in this last post is how to access the iProperties of other documents that are not being referenced by the active document, then you could use one of two different routes.&amp;nbsp; All iProperties are stored within Document objects, and the Document object must be open before you can access its iProperties.&amp;nbsp; So if you follow the normal Inventor API path to access them, instead of that iLogic shortcut snippet, you will not have to worry about anything.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Each &lt;A href="https://help.autodesk.com/view/INVNTOR/2024/ENU/?guid=GUID-Document" target="_blank" rel="noopener"&gt;Document&lt;/A&gt; type object (including PartDocument, AssemblyDocument, DrawingDocument, and others) has a direct property named &lt;A href="https://help.autodesk.com/view/INVNTOR/2024/ENU/?guid=Document_PropertySets" target="_blank" rel="noopener"&gt;PropertySets&lt;/A&gt;, which returns a &lt;A href="https://help.autodesk.com/view/INVNTOR/2024/ENU/?guid=GUID-PropertySets" target="_blank" rel="noopener"&gt;PropertySets&lt;/A&gt; type object.&amp;nbsp; That is a collection type that contains multiple &lt;A href="https://help.autodesk.com/view/INVNTOR/2024/ENU/?guid=GUID-PropertySet" target="_blank" rel="noopener"&gt;PropertySet&lt;/A&gt; type objects accessed by its &lt;A href="https://help.autodesk.com/view/INVNTOR/2024/ENU/?guid=PropertySets_Item" target="_blank" rel="noopener"&gt;Item&lt;/A&gt; property.&amp;nbsp; Then each PropertySet is also a collection type object which contains multiple &lt;A href="https://help.autodesk.com/view/INVNTOR/2024/ENU/?guid=GUID-Property" target="_blank" rel="noopener"&gt;Property&lt;/A&gt; objects, accessed through its &lt;A href="https://help.autodesk.com/view/INVNTOR/2024/ENU/?guid=PropertySet_Item" target="_blank" rel="noopener"&gt;Item&lt;/A&gt; property.&amp;nbsp; The Property object is nicknamed as iProperty.&amp;nbsp; There are at least 4 PropertySet objects found in every Document type object.&amp;nbsp; The first 3 PropertySets are the standard ones in which all the Property names &amp;amp; ID's can not be changed, and many of their values can not be changed either, but there are also several of the most common ones that have Read/Write values.&amp;nbsp; The fourth PropertySet is the 'custom' one, and it does not contain any Properties by default, until you either add some, or expose some Parameters as custom iProperties.&amp;nbsp; It is also possible for there to be multiple other PropertySets for other purposes.&amp;nbsp; For instance, parts generated by Content Center will often have 1 or 2 other PropertySets present which may contain Content Center related information specific to that document.&amp;nbsp; And when we add rules to the 'This Document' tab of the Event Triggers dialog, that saves those settings to a special hidden PropertySet in the background also.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So, an example of accessing a specific iProperty (like "Part Number") of a specific document would be something like the following.&lt;/P&gt;
&lt;LI-CODE lang="general"&gt;Dim oDoc As Document = ThisDoc.Document
Dim sPN As String = oDoc.PropertySets.Item("Design Tracking Properties").Item("Part Number").Value
MessageBox.Show("Part Number = " &amp;amp; sPN, "Part Number", MessageBoxButtons.OK, MessageBoxIcon.Information)&lt;/LI-CODE&gt;
&lt;P&gt;And to familiarize your self with what the names and Index positions of the PropertySets and Properties is, you can create a rule that iterates over each PropertySet, captures its information, then iterates through each of its Properties, captures its information, then reports about all of it at the end.&amp;nbsp; That is partially how I created the attached PDF of an Excel spreadsheet about the iProperties, to make it easier to find the ones I want, and help others out too.&lt;/P&gt;</description>
      <pubDate>Mon, 06 Nov 2023 13:34:09 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/changing-iproperties-with-ilogic/m-p/12356873#M159966</guid>
      <dc:creator>WCrihfield</dc:creator>
      <dc:date>2023-11-06T13:34:09Z</dc:date>
    </item>
    <item>
      <title>Re: Changing iProperties with iLogic</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/changing-iproperties-with-ilogic/m-p/12357017#M159970</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/8021187"&gt;@Daan_M&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;As&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/7812054"&gt;@WCrihfield&lt;/a&gt;&amp;nbsp;indicated we can use the API calls to get the property set, and the property, since you are working with the application's referenced documents, and not the referenced documents of an assembly.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here is an update to my previous 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" rel="noopener"&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;Dim&lt;/SPAN&gt; &lt;SPAN&gt;rDocs&lt;/SPAN&gt; &lt;SPAN&gt;As&lt;/SPAN&gt; &lt;SPAN&gt;Documents&lt;/SPAN&gt; = &lt;SPAN&gt;ThisApplication&lt;/SPAN&gt;.&lt;SPAN&gt;Documents&lt;/SPAN&gt;
&lt;SPAN&gt;For&lt;/SPAN&gt; &lt;SPAN&gt;Each&lt;/SPAN&gt; &lt;SPAN&gt;rDoc&lt;/SPAN&gt; &lt;SPAN&gt;As&lt;/SPAN&gt; &lt;SPAN&gt;Document&lt;/SPAN&gt; &lt;SPAN&gt;In&lt;/SPAN&gt; &lt;SPAN&gt;rDocs&lt;/SPAN&gt;
	&lt;SPAN&gt;oDoc&lt;/SPAN&gt; = &lt;SPAN&gt;ThisApplication&lt;/SPAN&gt;.&lt;SPAN&gt;Documents&lt;/SPAN&gt;.&lt;SPAN&gt;Open&lt;/SPAN&gt;(&lt;SPAN&gt;rDoc&lt;/SPAN&gt;.&lt;SPAN&gt;FullFileName&lt;/SPAN&gt;, &lt;SPAN&gt;True&lt;/SPAN&gt;)
	&lt;SPAN&gt;oDoc&lt;/SPAN&gt;.&lt;SPAN&gt;Activate&lt;/SPAN&gt;
	
	&lt;SPAN&gt;'get the property set&lt;/SPAN&gt;
	&lt;SPAN&gt;Dim&lt;/SPAN&gt; &lt;SPAN&gt;oDTPropSet&lt;/SPAN&gt; &lt;SPAN&gt;As&lt;/SPAN&gt; &lt;SPAN&gt;PropertySet&lt;/SPAN&gt;
	&lt;SPAN&gt;oDTPropSet&lt;/SPAN&gt; = &lt;SPAN&gt;oDoc&lt;/SPAN&gt;.&lt;SPAN&gt;PropertySets&lt;/SPAN&gt;.&lt;SPAN&gt;Item&lt;/SPAN&gt;(&lt;SPAN&gt;"Design Tracking Properties"&lt;/SPAN&gt;)	
	
	&lt;SPAN&gt;'get the property by name&lt;/SPAN&gt;
	&lt;SPAN&gt;Dim&lt;/SPAN&gt; &lt;SPAN&gt;oProperty&lt;/SPAN&gt; &lt;SPAN&gt;As&lt;/SPAN&gt; &lt;SPAN&gt;Inventor&lt;/SPAN&gt;.&lt;SPAN&gt;Property&lt;/SPAN&gt;
	&lt;SPAN&gt;oProperty&lt;/SPAN&gt; = &lt;SPAN&gt;oDTPropSet&lt;/SPAN&gt;.&lt;SPAN&gt;Item&lt;/SPAN&gt;(&lt;SPAN&gt;"Description"&lt;/SPAN&gt;)

	&lt;SPAN&gt;'set the value&lt;/SPAN&gt;
	 &lt;SPAN&gt;oProperty&lt;/SPAN&gt;.&lt;SPAN&gt;Value&lt;/SPAN&gt; = &lt;SPAN&gt;"Hello World"&lt;/SPAN&gt;

	&lt;SPAN&gt;MsgBox&lt;/SPAN&gt;(&lt;SPAN&gt;oDoc&lt;/SPAN&gt;.&lt;SPAN&gt;DisplayName&lt;/SPAN&gt; &amp;amp; &lt;SPAN&gt;vbLf&lt;/SPAN&gt; &amp;amp; &lt;SPAN&gt;oProperty&lt;/SPAN&gt;.&lt;SPAN&gt;DisplayName&lt;/SPAN&gt; &amp;amp; &lt;SPAN&gt;" = "&lt;/SPAN&gt; &amp;amp; &lt;SPAN&gt;oProperty&lt;/SPAN&gt;.&lt;SPAN&gt;Value&lt;/SPAN&gt;)	

	&lt;SPAN&gt;oDoc&lt;/SPAN&gt;.&lt;SPAN&gt;Save&lt;/SPAN&gt;()
	&lt;SPAN&gt;'oDoc.Close&lt;/SPAN&gt;
&lt;SPAN&gt;Next&lt;/SPAN&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 06 Nov 2023 14:28:35 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/changing-iproperties-with-ilogic/m-p/12357017#M159970</guid>
      <dc:creator>Curtis_Waguespack</dc:creator>
      <dc:date>2023-11-06T14:28:35Z</dc:date>
    </item>
  </channel>
</rss>

