Beispiel #1
0
    //------------------------------------------------------------------------------
    //  Explicit Activation
    //      This entry point is used to activate the application explicitly
    //------------------------------------------------------------------------------
    public static int Main(string[] args)
    {
        int retValue = 0;

        try
        {
            theProgram = new Program();

            //TODO: Add your application code here

            //int module_id;
            //theUfSession.UF.AskApplicationModule(out module_id);
            //if (module_id != UFConstants.UF_APP_DRAFTING)
            //{
            //    MessageBox.Show("請先轉換為製圖模組後再執行!");
            //    return retValue;
            //}

            Application.EnableVisualStyles();
            MEUploadDlg cMEUploadDlg = new MEUploadDlg();
            FormUtilities.ReparentForm(cMEUploadDlg);
            System.Windows.Forms.Application.Run(cMEUploadDlg);
            cMEUploadDlg.Dispose();

            theProgram.Dispose();
        }
        catch (NXOpen.NXException ex)
        {
            // ---- Enter your exception handling code here -----
        }
        return(retValue);
    }
Beispiel #2
0
    //------------------------------------------------------------------------------
    //  Explicit Activation
    //      This entry point is used to activate the application explicitly
    //------------------------------------------------------------------------------
    public static int Main(string[] args)
    {
        int retValue = 0;

        try
        {
            theProgram = new Program();

            //TODO: Add your application code here

            Application.EnableVisualStyles();
            MEUploadDlg cMEUploadDlg = new MEUploadDlg();
            FormUtilities.ReparentForm(cMEUploadDlg);
            System.Windows.Forms.Application.Run(cMEUploadDlg);
            cMEUploadDlg.Dispose();

            theProgram.Dispose();
        }
        catch (NXOpen.NXException ex)
        {
            // ---- Enter your exception handling code here -----
        }
        return(retValue);
    }