示例#1
0
 private void CopyText(ExcelHeaderFooterText from, ExcelHeaderFooterText to)
 {
     if (from == null)
     {
         return;
     }
     to.LeftAlignedText  = from.LeftAlignedText;
     to.CenteredText     = from.CenteredText;
     to.RightAlignedText = from.RightAlignedText;
 }
示例#2
0
        private string GetText(ExcelHeaderFooterText headerFooter)
        {
            string ret = "";

            if (headerFooter.LeftAlignedText != null)
            {
                ret += "&L" + headerFooter.LeftAlignedText;
            }
            if (headerFooter.CenteredText != null)
            {
                ret += "&C" + headerFooter.CenteredText;
            }
            if (headerFooter.RightAlignedText != null)
            {
                ret += "&R" + headerFooter.RightAlignedText;
            }
            return(ret);
        }