×
INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Jobs

Part attribute locked

Part attribute locked

Part attribute locked

(OP)
Hi everybody,

I want to delete a part attribute in NX9, but this is locked.
Are there any suggestions ?

RE: Part attribute locked

I think you can only unlock it and get rid of it using a journal. You most likely also have to change your customer defualts to allow you to lock an attribute through a journal. It is a checkmark somewhere. Also someone from siemens posted a journal for locked attributes on the gtac site.

RE: Part attribute locked

(OP)
Journal is a great hint.
Thank you.

RE: Part attribute locked

I recently heard a quote something along the lines of: "Before you tear down a fence, pause long enough to consider why it was put there in the first place".

www.nxjournaling.com

RE: Part attribute locked

What attribute are we talking about? Is it one that was generated by the system such as Material after assigning a materiall or is this something that perhaps Teamcenter added to your part file? As cowski has alluded to, think before you act.

Now if it was one that you inadvertently locked yourself, locked Attributes can only be unlocked via NX Open code.

John R. Baker, P.E.
Product 'Evangelist'
Product Engineering Software
Siemens PLM Software Inc.
Digital Factory
Cypress, CA
Siemens PLM:
UG/NX Museum:

To an Engineer, the glass is twice as big as it needs to be.

RE: Part attribute locked

(OP)
It is an attribute that was created by a tool to generate geometry.
The tool is not installed anymore, the geometry was deleted, but there where lots of modifications meanwhile.
I do not want to recreate everything because of that attribute.
So it es really a clean up. The "fence" does not make sense anymore.
I will check the nxopen help.
Thank you.

RE: Part attribute locked

A call to GTAC will help as well as they've had to intervene in situations like this before.

John R. Baker, P.E.
Product 'Evangelist'
Product Engineering Software
Siemens PLM Software Inc.
Digital Factory
Cypress, CA
Siemens PLM:
UG/NX Museum:

To an Engineer, the glass is twice as big as it needs to be.

RE: Part attribute locked

Try this code:

CODE --> VB

Option Strict Off
Imports System
Imports NXOpen
Imports NXOpen.UF

Module Unlock

    Private text As String
    Dim s As Session = Session.GetSession()
    Dim ufs As UFSession = UFSession.GetUFSession()

    Sub Main()

        Dim theSession As Session = Session.GetSession()
        Dim workPart As Part = theSession.Parts.Work
        Dim displayPart As Part = theSession.Parts.Display

        If workPart Is Nothing Then Return

        ' ----------------------------------------------
        '   Menu: File->Properties
        ' ----------------------------------------------
        Dim markId1 As Session.UndoMarkId
        markId1 = theSession.SetUndoMark(Session.MarkVisibility.Visible, "Unlock")
        ' ----------------------------------------------
        Dim p As BasePart = workPart

        If Not SelectText() Then
            Return
        End If

        Try
            p.SetUserAttributeLock(text, NXObject.AttributeType.Any, False)
        Catch ex As Exception
        End Try


    End Sub

    Function SelectText() As Boolean

        Dim theSession As Session = Session.GetSession()
        Dim workPart As Part = theSession.Parts.Work
        Dim theUISession As UI = UI.GetUI
        Dim answer As String = ""

        text = InputBox("Digite a Propriedade para Unlock", "UNLOCK Properties", "")

        If text.Length <> 0 Then
            SelectText = True
        End If

    End Function

    Public Function GetUnloadOption(ByVal dummy As String) As Integer

        'Unloads the image when the NX session terminates
        GetUnloadOption = NXOpen.Session.LibraryUnloadOption.AtTermination

    End Function

End Module 

Gelson Z. Nicoletto
Eng. Supervisor
Mould Desing
Brazil

RE: Part attribute locked

(OP)
Great !
Thank you !

RE: Part attribute locked

I have a part with locked attributes that are obsolete and couldn't delete them even though all references to them were removed. I didn't want to rebuild a complex set of relationships in a new file but just tried this routine and it worked great, thanks for sharing.

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members!


Resources