title: How to programmatically Paste CSV text into Excel and not just go into one cell? (C++)
body: <p>I have a list/grid in an MFC (c++) application.  I would like the user to be able to copy and paste the data into a spreadsheet.</p>
  
  <p>I've placed the data in the clipboard and the text makes it to the clipboard ok and I can paste it to notepad or Word or Excel, but Excel does not interpret the comma separated value-ness of my clipboard content - so it just goes into one cell/one column - rather than doing what I had hoped.</p>
  
  <p>I hope there is something simple I am missing.  </p>
  
  <p>Any suggestions to get this to work?</p>
  
  <p>I am not quite ready to make this a drag/drop source (which is in the task list)</p>
  
  <p>EDIT:</p>
  
  <p>I have it working - commas can't be used - must be tab separators</p>
  
  <p>But now there is a new problem:</p>
  
  <p>The issue now is that if I paste to excel using '\n' as line separator it looks good in excel but not in notepad.</p>
  
  <p>If I make it "\r\n" then notepad looks correct but excel then has blank lines.</p>
  
  <p>Any suggestions on how to make both consistent?</p>