Proper HTML Clipboard format for Excel

I write export tool for my application to copy several cells from table and paste that cells to microsoft excel (google docs, libreoffice calc). I use content-type text/html for my clipboard to copy also cell background color. How to mark table cell in source (my app) to not override adequate cell in destination (ie Excel)

Example copy scenario is: (# is any value and - is not-override-value)

###-#
-####
---##
#####

Now, if I put only empty <td></td> , when I paste my table into excel, that cells will overwrite existing cells and make them empty.

It works if I use content type text/csv because I can put many separators (ie t ) without passing value, ie:

#t#t#tttt# //some values are omitted
#t#t#t#ttt //some values are omitted

Is it possible to put a table into HTML clipboard? Table contains some empty cells and empty cells should not overwrite non-empty cells when pasting to Excel.

链接地址: http://www.djcxy.com/p/62268.html

上一篇: 使用nuget下载旧版本的软件包

下一篇: 适用于Excel的正确的HTML剪贴板格式