×
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

How to get the object of UF.UFModl using NX open ?

How to get the object of UF.UFModl using NX open ?

How to get the object of UF.UFModl using NX open ?

(OP)
Hello everyone ,

I need to get the symbolic thread parameters using NX open code, but to access the API "AskSymbThreadParms" i need to get the object of UF.UFModl.

Can someone please let me know how can i get the object of UF.UFModl in my code.

Regards,
Amitabh

RE: How to get the object of UF.UFModl using NX open ?

Basic steps are:
  1. import the UF namespace
  2. create a UFSession object
  3. call the UF function from your UFSession object
example code:

CODE

Option Strict Off  
Imports System  
Imports NXOpen  
Imports NXOpen.UF

Module Module1  

    Sub Main()  

        Dim theSession As Session = Session.GetSession()  
        Dim ufs As UFSession = UFSession.GetUFSession()

        Dim thread_tag As Tag = Tag.Null  
        Dim thread_data As UFModl.SymbThreadData  

 '
 '
 '

        ufs.Modl.AskSymbThreadParms(thread_tag, thread_data)

    End Sub  


    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 

www.nxjournaling.com

RE: How to get the object of UF.UFModl using NX open ?

(OP)
Thank you cowski, the solution works perfectly.
I was doing the steps 1 and 2 but missing the 3rd step.

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