private void fill_table(BomFeature bom) { found_bom = bom; string itno = string.Empty; string ptno = string.Empty; _cols.Clear(); _prts.Clear(); swTable = (ITableAnnotation)bom.IGetTableAnnotations(1); part.ClearSelection2(true); _col_count = swTable.ColumnCount; find_part_column(); _row_count = swTable.RowCount; for (int i = 0; i < _col_count; i++) { _cols.Add(swTable.get_DisplayedText(0, i)); } object[] bomtaa = (object[])bom.GetTableAnnotations(); BomTableAnnotation bta = (BomTableAnnotation)bomtaa[0]; int prtcol = get_column_by_name(_part_column); for (int i = 0; i < _row_count; i++) { string prt_ = swTable.get_DisplayedText(i, prtcol); _prts.Add(prt_); string[] pathnames = (string[])bta.GetModelPathNames(i, out itno, out ptno); if (pathnames != null) { foreach (string pathname in pathnames) { FileInfo fi_ = new FileInfo(pathname); path_list.Add(fi_); if (!path_dict.ContainsKey(prt_.ToUpper())) { path_dict.Add(prt_.ToUpper(), fi_); } } } } initialated = true; }
private void fill_table(BomFeature bom) { _cols.Clear(); _prts.Clear(); swTable = (ITableAnnotation)bom.IGetTableAnnotations(1); part.ClearSelection2(true); _col_count = swTable.ColumnCount; _row_count = swTable.RowCount; for (int i = 0; i < _col_count; i++) { _cols.Add(swTable.get_DisplayedText(0, i)); } int prtcol = get_column_by_name(_part_column); for (int i = 0; i < _row_count; i++) { _prts.Add(swTable.get_DisplayedText(i, prtcol)); } initialated = true; }
public ITableAnnotationObject(ITableAnnotation ITableAnnotationinstance) { ITableAnnotationInstance = ITableAnnotationinstance; }