List<CodeModule> _Items; // list of code module

        #endregion Fields

        #region Constructors

        internal CodeModules(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            _Items = new List<CodeModule>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                if (xNodeLoop.Name == "CodeModule")
                {
                    CodeModule cm = new CodeModule(r, this, xNodeLoop);
                    _Items.Add(cm);
                }
                else
                {
                    // don't know this element - log it
                    OwnerReport.rl.LogError(4, "Unknown CodeModules element '" + xNodeLoop.Name + "' ignored.");
                }
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "For CodeModules at least one CodeModule is required.");
            else
                _Items.TrimExcess();
        }
Example #2
0
        Expression _Hyperlink; // (URL)An expression that evaluates to the URL of the hyperlink

        #endregion Fields

        #region Constructors

        //An expression that evaluates to the ID of a
        //bookmark within the report to go to when this
        //report item is clicked on.
        //(If no bookmark with this ID is found, the link
        //will not be included in the report. If the
        //bookmark is hidden, the link will go to the start
        //of the page the bookmark is on. If multiple
        //bookmarks with this ID are found, the link will
        //go to the first one)
        // Constructor
        internal Action(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            _Hyperlink = null;
            _Drillthrough = null;
            _BookmarkLink = null;

            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "Hyperlink":
                        _Hyperlink = new Expression(r, this, xNodeLoop, ExpressionType.URL);
                        break;
                    case "Drillthrough":
                        _Drillthrough = new Drillthrough(r, this, xNodeLoop);
                        break;
                    case "BookmarkLink":
                        _BookmarkLink = new Expression(r, this, xNodeLoop, ExpressionType.String);
                        break;
                    default:
                        break;
                }
            }
        }
        RSize _Width; // Width of the row header

        #endregion Fields

        #region Constructors

        internal RowGrouping(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            _Width=null;
            _DynamicRows=null;
            _StaticRows=null;

            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "Width":
                        _Width = new RSize(r, xNodeLoop);
                        break;
                    case "DynamicRows":
                        _DynamicRows = new DynamicRows(r, this, xNodeLoop);
                        break;
                    case "StaticRows":
                        _StaticRows = new StaticRows(r, this, xNodeLoop);
                        break;
                    default:
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown RowGrouping element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
            }
            if (_Width == null)
                OwnerReport.rl.LogError(8, "RowGrouping requires the Width element.");
        }
        List<StaticMember> _Items; // list of StaticMember

        #endregion Fields

        #region Constructors

        internal StaticCategories(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            StaticMember sm;
            _Items = new List<StaticMember>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "StaticMember":
                        sm = new StaticMember(r, this, xNodeLoop);
                        break;
                    default:
                        sm=null;		// don't know what this is
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown StaticCategories element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
                if (sm != null)
                    _Items.Add(sm);
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "For StaticCategories at least one StaticMember is required.");
            else
                _Items.TrimExcess();
        }
        List<QueryParameter> _Items; // list of QueryParameter

        #endregion Fields

        #region Constructors

        internal QueryParameters(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            _ContainsArray = false;
            QueryParameter q;
            _Items = new List<QueryParameter>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "QueryParameter":
                        q = new QueryParameter(r, this, xNodeLoop);
                        break;
                    default:
                        q=null;		// don't know what this is
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown QueryParameters element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
                if (q != null)
                    _Items.Add(q);
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "For QueryParameters at least one QueryParameter is required.");
            else
                _Items.TrimExcess();
        }
Example #6
0
        List<DataValue> _Items; // list of DataValue

        #endregion Fields

        #region Constructors

        internal DataValues(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            DataValue dv;
            _Items = new List<DataValue>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "DataValue":
                        dv = new DataValue(r, this, xNodeLoop);
                        break;
                    default:
                        dv=null;		// don't know what this is
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown DataValues element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
                if (dv != null)
                    _Items.Add(dv);
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "For DataValues at least one DataValue is required.");
            else
                _Items.TrimExcess();
        }
Example #7
0
        TableRows _TableRows; // The header rows for the table or group

        #endregion Fields

        #region Constructors

        // each page that the table (or group) is displayed
        internal Header(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            _TableRows=null;
            _RepeatOnNewPage=false;

            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "TableRows":
                        _TableRows = new TableRows(r, this, xNodeLoop);
                        break;
                    case "RepeatOnNewPage":
                        _RepeatOnNewPage = XmlUtil.Boolean(xNodeLoop.InnerText, OwnerReport.rl);
                        break;
                    default:
                        break;
                }
            }
            if (_TableRows == null)
                OwnerReport.rl.LogError(8, "Header requires the TableRows element.");
        }
        Style _Style; // Line style properties for the gridlines and tickmarks

        #endregion Fields

        #region Constructors

        internal ChartGridLines(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            _ShowGridLines=true;
            _Style=null;

            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "ShowGridLines":
                        _ShowGridLines = XmlUtil.Boolean(xNodeLoop.InnerText, OwnerReport.rl);
                        break;
                    case "Style":
                        _Style = new Style(r, this, xNodeLoop);
                        break;
                    default:	// TODO
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown ChartGridLines element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
            }
        }
        List<SeriesGrouping> _Items; // list of SeriesGrouping

        #endregion Fields

        #region Constructors

        internal SeriesGroupings(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            SeriesGrouping sg;
            _Items = new List<SeriesGrouping>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "SeriesGrouping":
                        sg = new SeriesGrouping(r, this, xNodeLoop);
                        break;
                    default:
                        sg=null;		// don't know what this is
                        break;
                }
                if (sg != null)
                    _Items.Add(sg);
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "For SeriesGroupings at least one SeriesGrouping is required.");
            else
                _Items.TrimExcess();
        }
Example #10
0
        MarkerTypeEnum _Type; // Defines the marker type for values. Default: none

        #endregion Fields

        #region Constructors

        //  properties for the marker(s).
        internal Marker(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            _Type=MarkerTypeEnum.None;
            _Size=null;
            _Style=null;

            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "Type":
                        _Type = MarkerType.GetStyle(xNodeLoop.InnerText, OwnerReport.rl);
                        break;
                    case "Size":
                        _Size = new RSize(r, xNodeLoop);
                        break;
                    case "Style":
                        _Style = new Style(r, this, xNodeLoop);
                        break;
                    default:
                        break;
                }
            }
        }
        StaticColumns _StaticColumns; // Static column headings for this grouping

        #endregion Fields

        #region Constructors

        internal ColumnGrouping(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            _Height=null;
            _DynamicColumns=null;
            _StaticColumns=null;

            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "Height":
                        _Height = new RSize(r, xNodeLoop);
                        break;
                    case "DynamicColumns":
                        _DynamicColumns = new DynamicColumns(r, this, xNodeLoop);
                        break;
                    case "StaticColumns":
                        _StaticColumns = new StaticColumns(r, this, xNodeLoop);
                        break;
                    default:
                        break;
                }
            }
            if (_Height == null)
                OwnerReport.rl.LogError(8, "ColumnGrouping requires the Height element to be specified.");

            if ((_DynamicColumns != null && _StaticColumns != null) ||
                (_DynamicColumns == null && _StaticColumns == null))
                OwnerReport.rl.LogError(8, "ColumnGrouping requires either the DynamicColumns element or StaticColumns element but not both.");
        }
Example #12
0
        MatrixCells _MatrixCells; // The set of cells in a row in the detail section of the Matrix.

        #endregion Fields

        #region Constructors

        internal MatrixRow(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            _Height=null;
            _MatrixCells=null;

            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "Height":
                        _Height = new RSize(r, xNodeLoop);
                        break;
                    case "MatrixCells":
                        _MatrixCells = new MatrixCells(r, this, xNodeLoop);
                        break;
                    default:
                        break;
                }
            }
            if (_MatrixCells == null)
                OwnerReport.rl.LogError(8, "MatrixRow requires the MatrixCells element.");
        }
Example #13
0
        List<Filter> _Items; // list of Filter

        #endregion Fields

        #region Constructors

        internal Filters(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            Filter f;
            _Items = new List<Filter>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "Filter":
                        f = new Filter(r, this, xNodeLoop);
                        break;
                    default:
                        f=null;		// don't know what this is
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown Filters element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
                if (f != null)
                    _Items.Add(f);
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "Filters require at least one Filter be defined.");
            else
                _Items.TrimExcess();
        }
        Style _Style; // border and background properties for series legend itmes and data points

        #endregion Fields

        #region Constructors

        //   when dynamic exprs are evaluated per group instance
        internal SeriesGrouping(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            _DynamicSeries=null;
            _StaticSeries=null;
            _Style=null;

            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "DynamicSeries":
                        _DynamicSeries = new DynamicSeries(r, this, xNodeLoop);
                        break;
                    case "StaticSeries":
                        _StaticSeries = new StaticSeries(r, this, xNodeLoop);
                        break;
                    case "Style":
                        _Style = new Style(OwnerReport, this, xNodeLoop);
                        OwnerReport.rl.LogError(4, "Style element in SeriesGrouping is currently ignored."); // TODO
                        break;
                    default:
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown SeriesGrouping element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
            }
        }
        Expression _Top; //(Size) Width of the top border. Max: 20 pt Min: 0.25 pt

        #endregion Fields

        #region Constructors

        internal StyleBorderWidth(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            _Default=null;
            _Left=null;

            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "Default":
                        _Default = new Expression(r, this, xNodeLoop, ExpressionType.ReportUnit);
                        break;
                    case "Left":
                        _Left = new Expression(r, this, xNodeLoop, ExpressionType.ReportUnit);
                        break;
                    case "Right":
                        _Right = new Expression(r, this, xNodeLoop, ExpressionType.ReportUnit);
                        break;
                    case "Top":
                        _Top = new Expression(r, this, xNodeLoop, ExpressionType.ReportUnit);
                        break;
                    case "Bottom":
                        _Bottom = new Expression(r, this, xNodeLoop, ExpressionType.ReportUnit);
                        break;
                    default:
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown BorderWidth element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
            }
        }
Example #16
0
        ReportItems _ReportItems; // Report items contained within the bounds of the rectangle.

        #endregion Fields

        #region Constructors

        // constructor that doesn't process syntax
        internal Rectangle(ReportDefn r, ReportLink p, XmlNode xNode, bool bNoLoop)
            : base(r,p,xNode)
        {
            _ReportItems=null;
            _PageBreakAtStart=false;
            _PageBreakAtEnd=false;
        }
Example #17
0
        List<MatrixRow> _Items; // list of MatrixRow

        #endregion Fields

        #region Constructors

        internal MatrixRows(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            MatrixRow m;
            _Items = new List<MatrixRow>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "MatrixRow":
                        m = new MatrixRow(r, this, xNodeLoop);
                        break;
                    default:
                        m=null;		// don't know what this is
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown MatrixRows element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
                if (m != null)
                    _Items.Add(m);
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "For MatrixRows at least one MatrixRow is required.");
            else
                _Items.TrimExcess();
        }
Example #18
0
        internal Rectangle(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r,p,xNode)
        {
            _ReportItems=null;
            _PageBreakAtStart=false;
            _PageBreakAtEnd=false;

            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "ReportItems":
                        _ReportItems = new ReportItems(r, this, xNodeLoop);
                        break;
                    case "PageBreakAtStart":
                        _PageBreakAtStart = XmlUtil.Boolean(xNodeLoop.InnerText, OwnerReport.rl);
                        break;
                    case "PageBreakAtEnd":
                        _PageBreakAtEnd = XmlUtil.Boolean(xNodeLoop.InnerText, OwnerReport.rl);
                        break;
                    default:
                        if (ReportItemElement(xNodeLoop))	// try at ReportItem level
                            break;
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown Rectangle element " + xNodeLoop.Name + " ignored.");
                        break;
                }
            }
        }
        List<SubreportParameter> _Items; // list of SubreportParameter

        #endregion Fields

        #region Constructors

        internal SubReportParameters(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            SubreportParameter rp;
            _Items = new List<SubreportParameter>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "Parameter":
                        rp = new SubreportParameter(r, this, xNodeLoop);
                        break;
                    default:
                        rp=null;		// don't know what this is
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown SubreportParameters element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
                if (rp != null)
                    _Items.Add(rp);
            }
            if (_Items.Count > 0)
                _Items.TrimExcess();
        }
        List<GroupExpression> _Items; // list of GroupExpression

        #endregion Fields

        #region Constructors

        internal GroupExpressions(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            GroupExpression g;
            _Items = new List<GroupExpression>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "GroupExpression":
                        g = new GroupExpression(r, this, xNodeLoop);
                        break;
                    default:
                        g=null;		// don't know what this is
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown GroupExpressions element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
                if (g != null)
                    _Items.Add(g);
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "GroupExpressions require at least one GroupExpression be defined.");
            else
                _Items.TrimExcess();
        }
Example #21
0
        List<SortBy> _Items; // list of SortBy

        #endregion Fields

        #region Constructors

        internal Sorting(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            SortBy s;
            _Items = new List<SortBy>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "SortBy":
                        s = new SortBy(r, this, xNodeLoop);
                        break;
                    default:
                        s=null;		// don't know what this is
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown Sorting element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
                if (s != null)
                    _Items.Add(s);
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "Sorting requires at least one SortBy be defined.");
            else
                _Items.TrimExcess();
        }
        string _ReportName; // URL The path of the drillthrough report. Paths may be

        #endregion Fields

        #region Constructors

        internal Drillthrough(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            _ReportName=null;
            _DrillthroughParameters=null;

            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "ReportName":
                        _ReportName = xNodeLoop.InnerText;
                        break;
                    case "Parameters":
                        _DrillthroughParameters = new DrillthroughParameters(r, this, xNodeLoop);
                        break;
                    default:
                        break;
                }
            }
            if (_ReportName == null)
                OwnerReport.rl.LogError(8, "Drillthrough requires the ReportName element.");
        }
        Sorting _Sorting; // The expressions to sort the data by

        #endregion Fields

        #region Constructors

        internal DynamicCategories(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            _Grouping=null;
            _Sorting=null;
            _Label=null;

            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "Grouping":
                        _Grouping = new Grouping(r, this, xNodeLoop);
                        break;
                    case "Sorting":
                        _Sorting = new Sorting(r, this, xNodeLoop);
                        break;
                    case "Label":
                        _Label = new Expression(r, this, xNodeLoop, ExpressionType.Variant);
                        break;
                    default:
                        break;
                }
            }
            if (_Grouping == null)
                OwnerReport.rl.LogError(8, "DynamicCategories requires the Grouping element.");
        }
Example #24
0
        TableRows _TableRows; // The footer rows for the table or group

        #endregion Fields

        #region Constructors

        // each page that the table (or group) is displayed
        internal Footer(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            _TableRows=null;
            _RepeatOnNewPage=false;

            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "TableRows":
                        _TableRows = new TableRows(r, this, xNodeLoop);
                        break;
                    case "RepeatOnNewPage":
                        _RepeatOnNewPage = XmlUtil.Boolean(xNodeLoop.InnerText, OwnerReport.rl);
                        break;
                    default:
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown Footer element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
            }
            if (_TableRows == null)
                OwnerReport.rl.LogError(8, "TableRows element is required with a Footer but not specified.");
        }
        StaticCategories _StaticCategories; // Category headings for this grouping

        #endregion Fields

        #region Constructors

        internal CategoryGrouping(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            _DynamicCategories=null;
            _StaticCategories=null;

            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "DynamicCategories":
                        _DynamicCategories = new DynamicCategories(r, this, xNodeLoop);
                        break;
                    case "StaticCategories":
                        _StaticCategories = new StaticCategories(r, this, xNodeLoop);
                        break;
                    default:
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown CategoryGrouping element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
            }
            if ((_DynamicCategories == null && _StaticCategories == null) ||
                (_DynamicCategories != null && _StaticCategories != null))
                OwnerReport.rl.LogError(8, "CategoryGrouping requires either DynamicCategories element or StaticCategories element, but not both.");
        }
Example #26
0
        List<TableGroup> _Items; // list of TableGroup entries

        #endregion Fields

        #region Constructors

        internal TableGroups(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            TableGroup tg;
            _Items = new List<TableGroup>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "TableGroup":
                        tg = new TableGroup(r, this, xNodeLoop);
                        break;
                    default:
                        tg=null;		// don't know what this is
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown TableGroups element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
                if (tg != null)
                    _Items.Add(tg);
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "For TableGroups at least one TableGroup is required.");
            else
                _Items.TrimExcess();
        }
Example #27
0
        List<TableCell> _Items; // list of TableCell

        #endregion Fields

        #region Constructors

        internal TableCells(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            TableCell tc;
            _Items = new List<TableCell>();
            // Loop thru all the child nodes
            int colIndex=0;			// keep track of the column numbers
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "TableCell":
                        tc = new TableCell(r, this, xNodeLoop, colIndex);
                        colIndex += tc.ColSpan;
                        break;
                    default:
                        tc=null;		// don't know what this is
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown TableCells element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
                if (tc != null)
                    _Items.Add(tc);
            }
            if (_Items.Count > 0)
                _Items.TrimExcess();
        }
 internal RowGroupings(ReportDefn r, ReportLink p, XmlNode xNode)
     : base(r, p)
 {
     RowGrouping g;
     _Items = new List<RowGrouping>();
     // Loop thru all the child nodes
     foreach(XmlNode xNodeLoop in xNode.ChildNodes)
     {
         if (xNodeLoop.NodeType != XmlNodeType.Element)
             continue;
         switch (xNodeLoop.Name)
         {
             case "RowGrouping":
                 g = new RowGrouping(r, this, xNodeLoop);
                 break;
             default:
                 g=null;		// don't know what this is
                 // don't know this element - log it
                 OwnerReport.rl.LogError(4, "Unknown RowGroupings element '" + xNodeLoop.Name + "' ignored.");
                 break;
         }
         if (g != null)
             _Items.Add(g);
     }
     if (_Items.Count == 0)
         OwnerReport.rl.LogError(8, "For RowGroupings at least one RowGrouping is required.");
     else
     {
         _Items.TrimExcess();
         _StaticCount = GetStaticCount();
     }
 }
Example #29
0
        string _ToggleItem; // The name of the textbox used to

        #endregion Fields

        #region Constructors

        // hide/unhide this report item. Clicking on
        //an instance of the ToggleItem will toggle
        //the hidden state of every corresponding
        //instance of this item. If the Toggle item
        //becomes hidden, this item should become
        //hidden.
        //Must be a textbox in the same grouping
        //scope as this item or in any containing (ancestor) grouping scope
        //If omitted, no item will toggle the hidden
        //state of this item.
        //Not allowed on and cannot refer to report
        //items contained in a page header or
        //footer.
        //Cannot refer to a report item contained
        //within the current report item unless
        //current grouping scope has a Parent.
        internal Visibility(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            _Hidden=null;
            _ToggleItem=null;

            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "Hidden":
                        _Hidden = new Expression(r, this, xNodeLoop, ExpressionType.Boolean);
                        break;
                    case "ToggleItem":
                        _ToggleItem = xNodeLoop.InnerText;
                        break;
                    default:
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown Visibility element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
            }
        }
Example #30
0
        List<ChartSeries> _Items; // list of chart series

        #endregion Fields

        #region Constructors

        internal ChartData(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            ChartSeries cs;
            _Items = new List<ChartSeries>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "ChartSeries":
                        cs = new ChartSeries(r, this, xNodeLoop);
                        break;
                    default:
                        cs=null;		// don't know what this is
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown ChartData element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
                if (cs != null)
                    _Items.Add(cs);
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "For ChartData at least one ChartSeries is required.");
            else
                _Items.TrimExcess();
        }