Announcements
Attention for Customers without Multi-Factor Authentication or Single Sign-On - OTP Verification rolls out April 2025. Read all about it here.
JelteDeJong
in reply to: iogurt1

you can try this:

Dim doc As AssemblyDocument = ThisDoc.Document

For Each oOccurrence As ComponentOccurrence In doc.ComponentDefinition.Occurrences

    If iProperties.Value(oOccurrence.Name, "Status", "Status") = "" Then
        iProperties.Value(oOccurrence.Name, "Custom", "TEST") = iProperties.Value(oOccurrence.Name, "Project", "Part Number") & iProperties.Value(oOccurrence.Name, "Project", "Revision Number")
    Else
        iProperties.Value(oOccurrence.Name, "Custom", "TEST") = iProperties.Value(oOccurrence.Name, "Project", "Part Number") & iProperties.Value(oOccurrence.Name, "Project", "Revision Number") & "_P" & iProperties.Value(oOccurrence.Name, "Status", "Status")
    End If

Next

'auf .iam Ebene
If iProperties.Value("Status", "Status") = "" Then
    iProperties.Value("Custom", "TEST") = iProperties.Value("Project", "Part Number") & iProperties.Value("Project", "Revision Number")
Else
    iProperties.Value("Custom", "TEST") = iProperties.Value("Project", "Part Number") & iProperties.Value("Project", "Revision Number") & "_P" & iProperties.Value("Status", "Status")
End If

Jelte de Jong
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.

EESignature


Blog: hjalte.nl - github.com