title: Export to excel from gridview c# format Header text
body: <p>I am exporting to excel from gridview. Is there any way to format the header text and wrap it in the excel ?.
  My export to excel code as </p>
  
  <pre><code> grdCommon.Font.Size = FontUnit.XSmall;
   grdCommon.GridLines = GridLines.Both;
   grdCommon.Style["font-family"] = "Arial, Helvetica, sans-serif;";
   grdCommon.HeaderStyle.HorizontalAlign = HorizontalAlign.Center;
   grdCommon.HeaderStyle.ForeColor = System.Drawing.Color.White;
   grdCommon.HeaderStyle.BackColor = System.Drawing.Color.FromArgb(80, 124, 209);
   grdCommon.HeaderStyle.Font.Size = 8;
   grdCommon.HeaderStyle.Width = 30;
  </code></pre>
  
  <p>I tried adding as below to format the header column in excel. but the excel header doesnt gets wraped </p>
  
  <pre><code> grdCommon.HeaderRow.Style.Value = "word-break:break-all;word-wrap:break-word";
   grdCommon.HeaderRow.Cells[0].Wrap = true;
  </code></pre>
  
  <p>and modified this method  </p>
  
  <pre><code> grdCommon.HeaderRow.Style.Add("background-color", "#FFFFFF"); as 
   grdCommon.HeaderRow.Style.Add("word-wrap","true");
  </code></pre>
  
  <p>Any suggestions...</p>