private IEnumerable <Internal.QueryCellInfo> _enum_total_cellinfo(int shapeid, int shapeindex) { // enum Cells foreach (var col in this.Cells) { var sidsrc = new SidSrc((short)shapeid, col.Src); var cellinfo = new Internal.QueryCellInfo(sidsrc, col); yield return(cellinfo); } // enum SubQueries if (this._cache.CountShapes > 0) { var section_infos = _cache.GetSectionInfosForShapeAtIndex(shapeindex); foreach (var section_info in section_infos) { foreach (int rowindex in section_info.RowIndexes) { foreach (var col in section_info.SubQuery.Columns) { var src = new VisioAutomation.ShapeSheet.Src( (short)section_info.SubQuery.SectionIndex, (short)rowindex, col.CellIndex); var sidsrc = new VisioAutomation.ShapeSheet.SidSrc((short)shapeid, src); var cellinfo = new Internal.QueryCellInfo(sidsrc, col); yield return(cellinfo); } } } } }
private List <SectionInfo> GetSectionInfoForShape(int shape_index, SectionInfoCache cache) { if (cache.CountShapes > 0) { return(cache.GetSectionInfosForShapeAtIndex(shape_index)); } return(null); }