public object Clone() { Cell newCell = (Cell)this.MemberwiseClone(); if (this.HasEmbeddedReport) { newCell.EmbeddedReport = EmbedReport.LoadAndParse(this.NonNumbericText); } return(newCell); }
/// <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); } }
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"; }
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); } }
/// <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)); }