Ejemplo n.º 1
0
        public object Clone()
        {
            Cell newCell = (Cell)this.MemberwiseClone();

            if (this.HasEmbeddedReport)
            {
                newCell.EmbeddedReport = EmbedReport.LoadAndParse(this.NonNumbericText);
            }

            return(newCell);
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Load, and then parse, the given <paramref
        /// name="embeddingInstruction"/>.
        /// </summary>
        /// <param name="embeddingInstruction">The embed command to parse.
        /// </param>
        /// <param name="embedWarning">A <see cref="string"/> containing any
        /// warnings enountered during parsing.</param>
        /// <returns>An <see cref="EmbedReport"/> object for the given embed
        /// command.</returns>
        public static EmbedReport LoadAndParse(string embeddingInstruction, out string embedWarning)
        {
            EmbedReport report = new EmbedReport(embeddingInstruction);

            if (report.Parse(out embedWarning))
            {
                return(report);
            }
            else
            {
                return(null);
            }
        }
Ejemplo n.º 3
0
        public void Clear()
        {
            this.DisplayDateInUSFormat = false;
            this.DisplayZeroAsNone     = false;

            this.EmbeddedReport = null;

            this.IsNumeric = false;
            this.IsRatio   = false;

            this.NumericAmount        = 0;
            this.NonNumbericText      = string.Empty;
            this.RoundedNumericAmount = "0";
        }
Ejemplo n.º 4
0
        private void SetValues(Cell rc)
        {
            this.ContextID = rc.ContextID;
            this.UnitID    = rc.UnitID;

            this.DisplayDateInUSFormat = rc.DisplayDateInUSFormat;
            this.DisplayZeroAsNone     = rc.DisplayZeroAsNone;

            this.FootnoteIndexer = rc.FootnoteIndexer;

            this.IsNumeric = rc.IsNumeric;
            this.IsRatio   = rc.IsRatio;

            this.NonNumbericText = rc.NonNumbericText;
            this.NumericAmount   = rc.NumericAmount;

            this.RoundedNumericAmount = rc.RoundedNumericAmount;
            this.ShowCurrencySymbol   = rc.ShowCurrencySymbol;

            if (EmbedReport.HasMatch(rc.NonNumbericText))
            {
                this.EmbeddedReport = EmbedReport.LoadAndParse(rc.NonNumbericText);
            }
        }
Ejemplo n.º 5
0
        /// <summary>
        /// Load, and then parse, the given <paramref
        /// name="embeddingInstruction"/>.
        /// </summary>
        /// <param name="embeddingInstruction">The embed command to parse.
        /// </param>
        /// <returns>An <see cref="EmbedReport"/> object for the given embed
        /// command.</returns>
        public static EmbedReport LoadAndParse(string embeddingInstruction)
        {
            string embedWarning = string.Empty;

            return(EmbedReport.LoadAndParse(embeddingInstruction, out embedWarning));
        }