title: Is posible edit opened excel file
body: <p>I exporting some data to existing excel file. Problem is that, user can have this file opened.</p>
  
  <p>For reading and writing to excel I use <Code>Microsoft.Office.Interop.Excel.</Code></p>
  
  <p>Is possible edit file with showing changes in Excel desktop app?
  Or is possible to check if file is opened in excel?</p>
  
  <p>this is how I open that file:</p>
  
  <pre><code>xlApp = new Excel.Application();
  xlApp.DisplayAlerts = false;
  workbook = xlApp.Workbooks;
  xlWorkBook = workbook.Open(filePath, 0, false, 5, "", "", false, Microsoft.Office.Interop.Excel.XlPlatform.xlWindows, "\t", true, false, 0, true, false, false);
  var worksheets = xlWorkBook.Worksheets;
  </code></pre>
  
  <p>than I iterate over all sheets and fill data with writing values to Cells</p>
  
  <pre><code>Excel.Worksheet xlWorkSheet = worksheets.get_Item(sheetIndex);
  Excel.Range range = GetRange(xlWorkSheet);
  
  range.Cells[row,column] = value;
  </code></pre>
  
  <p></p>
  
  <p>Then I save file:</p>
  
  <pre><code>xlWorkBook.Save();
  </code></pre>
  
  <p>Thank you
  Jakub</p>