Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations cowski on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Journal and view triad? 1

Status
Not open for further replies.

kukelyk

Industrial
Joined
Mar 21, 2005
Messages
315
Location
HU
Hi.
Is it possible to switch on and off the view triad by journal?
Thanks in advance

----
kukelyk
 
Following code turns the triad off and then on again.

Code:
using System;
using NXOpen;

public class ViewTriadHideNShow
{
    public static void Main(string[] args)
    {
        Session theSession = Session.GetSession();
        UI theUI = UI.GetUI();

        NXOpen.Preferences.SessionPreferences sesPrefs = theSession.Preferences;

        sesPrefs.ScreenVisualization.TriadVisibility = 0;

        theUI.NXMessageBox.Show("Triad", NXMessageBox.DialogType.Information, "Turned Off now");

        sesPrefs.ScreenVisualization.TriadVisibility = 1;
                

    }
    public static int GetUnloadOption(string dummy) { return (int)Session.LibraryUnloadOption.Immediately; }
}

Suresh
 
Thanks. Is this code in c#?
Can I run it from journal?

----
kukelyk
 
Great, thanks

----
kukelyk
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top