Ejemplo n.º 1
0
        private static string resolve_to_part(System.IO.FileInfo fi)
        {
            string res = string.Empty;

            System.Text.RegularExpressions.MatchCollection mc;
            System.Text.RegularExpressions.Regex           rx =
                new System.Text.RegularExpressions.Regex(Properties.Settings.Default.CNCProgramFileNameRegex);
            mc = rx.Matches(fi.Name);
            switch (mc.Count)
            {
            case 3:
                res = mc[1].Value;
                break;

            case 2:
                res = mc[0].Value;
                break;

            case 1:
                res = mc[0].Value;
                break;

            default:
                res = "AAAAAAAAAA";
                break;
            }
            return(ENGINEERINGDataSet.get_part_by_prog(res));
        }
Ejemplo n.º 2
0
        public Dictionary <int, int> get_priority_values()
        {
            int p = 0;

            if (comboBox1.SelectedValue != null &&
                int.TryParse(comboBox1.SelectedValue.ToString(), out p))
            {
                return(ENGINEERINGDataSet.get_priority_values_inner(p));
            }
            return(new Dictionary <int, int>());
        }
Ejemplo n.º 3
0
        private void apply_changes()
        {
            DataRowView comboboxitem = (DataRowView)comboBox1.SelectedItem;

            ENGINEERINGDataSet.update_priority_values((int)comboboxitem[0], get_listbox_states());
        }