public CCSupportBarControl1() { InitializeComponent(); // 將資料交由 InfoObjectFactory 管理 CCSupportBarInfo info = new CCSupportBarInfo(); InfoObjectFactory.AddInfoObj(info.Name, info); }
public CCClampTeachControl1() { InitializeComponent(); // 將資料交由 InfoObjectFactory 管理 CCClampTeachInfo info = new CCClampTeachInfo(); InfoObjectFactory.AddInfoObj(info.Name, info); m_cbAxis.SelectedIndex = 0; }
private void m_btnAxisSave_Click(object sender, EventArgs e) { SaveFileDialog DialogSave = new SaveFileDialog(); DialogSave.InitialDirectory = InfoObjectFactory.GetInfoObject("Clamp Teach").IniDirPath; DialogSave.Filter = "Ini file (*.ini)|"; DialogSave.DefaultExt = "ini"; if (DialogSave.ShowDialog() == DialogResult.OK) { if (DialogSave.FileName != "") { IniFile iniFile = new IniFile(DialogSave.FileName); /*iniFile.WriteValue("Alignment X", "Position", m_tbxAlignXClamp.Text); * iniFile.WriteValue("Alignment Y", "Position", m_tbxAlignYClamp.Text); * iniFile.WriteValue("Bar1", "Position", m_tbxAlignYClamp.Text); * iniFile.WriteValue("Bar2", "Position", m_tbxAlignYClamp.Text); */ } } DialogSave.Dispose(); DialogSave = null; }