title: C# -How to deselect wrap in the whole Excel file Using C#
body: <p>i have create the <code>Excel</code> File But <code>Wrap Text</code> Automatically <code>Excel</code> Selected but i want to my project run and excel will be open then Wrap Text deselected in <code>excel</code> file 
  <strong>I am Not Used the RANGE Class without Work in excel..</strong></p>
  
  <p>i am data all Transfer to <code>excel</code> but name filed using but some cases using the long name then row automatically next line generated then i am deselected wrap text then properly view the <code>excel</code> data format </p>
  
  <p>i am using the <code>C# Windows Application</code> and Excel version <code>Microsoft-Office-2016</code></p>
  
  <p><strong>My code</strong></p>
  
  <p>Excel Open Code..</p>
  
  <pre><code> Microsoft.Office.Interop.Excel.Application ExcelApp = new 
   Microsoft.Office.Interop.Excel.Application();
                  Workbook xlWorkBook = 
   ExcelApp.Workbooks.Add(Microsoft.Office.Interop.Excel.XlWBATemplate.xlWBATWorksheet);
  </code></pre>
  
  <p>I am Using the Looping..</p>
  
  <pre><code> foreach (DataColumn column in dtDataTable1.Columns)
              {
                  sb.Append("&lt;td style='border: 1px solid black'&gt;" + column.ColumnName + "&lt;/td&gt;");
              }
              sb.Append("&lt;/tr&gt;");
              ExcelApp.Windows.Application.ActiveWindow.DisplayGridlines = false;
              StringBuilder objSB = new StringBuilder();
  
              foreach (DataRow row in dtDataTable1.Rows)
              {
                  sb.Append("&lt;tr&gt;");
  
                  sb.Append("&lt;td style='width:100px;border: 1px solid black'&gt;" + index.ToString() + "&lt;/td&gt;");
                  foreach (DataColumn column in dtDataTable1.Columns)
                  {
                      sb.Append("&lt;td style='width:100px;border: 1px solid black'&gt;" + row[column.ColumnName].ToString() + "&lt;/td&gt;");
                  }
                  index++;
                  sb.Append("&lt;/tr&gt;");
              }
  </code></pre>
  
  <p>Data will Export in excel</p>
  
  <p><strong>Show excel Store file</strong></p>
  
  <pre><code> Microsoft.Office.Interop.Excel.Application Excel = new Microsoft.Office.Interop.Excel.Application();
              Workbook xlWorkBook1 = ExcelApp.Workbooks.Add(Microsoft.Office.Interop.Excel.XlWBATemplate.xlWBATWorksheet);
              xlWorkBook1 = Excel.Workbooks.Open("C:\\Users\\Krupal\\Desktop\\" + Todaysdate + "\\Summury_final " + Convert.ToDateTime(cmbmonth.SelectedItem).ToString("dd/MM/yyyy") + ".XLS", 0, true, 5, "", "", true, Microsoft.Office.Interop.Excel.XlPlatform.xlWindows, "\t", false, false, 0, true, 1, 0);
              Microsoft.Office.Interop.Excel.Worksheet Wt = (Excel.Worksheet)xlWorkBook1.Worksheets.get_Item(1);
              Excel.Visible = true;
  </code></pre>
  
  <p>Please help me 
  Advance Thank You</p>