Beispiel #1
0
        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);
                        }
                    }
                }
            }
        }
Beispiel #2
0
        public void SetFormula(short id, VisioAutomation.ShapeSheet.Src src, string formula)
        {
            var sidsrc = new VisioAutomation.ShapeSheet.SidSrc(id, src);

            this.writer.SetFormula(sidsrc, formula);
        }
Beispiel #3
0
        public void AddCell(short id, VisioAutomation.ShapeSheet.Src src)
        {
            var sidsrc = new VisioAutomation.ShapeSheet.SidSrc(id, src);

            this.SidSrcStreamBuilder.Add(sidsrc);
        }