예제 #1
0
        public Form8()
        {
            InitializeComponent();

            adsPlcServer = MainApp.GetDoc().AdsPlcServer;
            adsNcServer  = MainApp.GetDoc().AdsNcServer;
        }
예제 #2
0
        private void OPModeAuto_Load(object sender, System.EventArgs e)
        {
            if (MainApp.GetDoc() != null)
            {
                adsPlcServer = MainApp.GetDoc().AdsPlcServer;
                adsNcServer  = MainApp.GetDoc().AdsNcServer;
                tcNcProgramSection1.AdsNcServer = adsNcServer;
                selectFile1.FileName            = MainApp.appSettings.batchProcess[4];

                TypeConverter tc      = TypeDescriptor.GetConverter(typeof(Font));
                Font          newFont = (Font)tc.ConvertFromString(MainApp.appSettings.ncFontName);
                tcNcProgramSection1.Font = newFont;

                int[] stops = { MainApp.appSettings.ncTabWidth };
                SendMessage(tcNcProgramSection1.RichTextBoxHandle, EM_SETTABSTOPS, 1, stops);
            }
        }