我必须使用C#和提取Excel文件的创建日期Microsoft.Office.Interop.Excel.Worksheet
。我将获得属性
object props = myworkbook.CustomDocumentProperties;
现在,我不确定如何从该对象获取创建日期。
本Creation Date
可以在发现BuiltinDocumentProperties它返回一个属性Microsoft.Office.Core.DocumentProperties
代表所有工作簿的内置文档属性的集合。
Microsoft.Office.Core.DocumentProperties properties;
properties = (Microsoft.Office.Core.DocumentProperties)Globals.ThisWorkbook.BuiltinDocumentProperties;
Microsoft.Office.Core.DocumentProperty prop;
prop = properties["Creation Date"];
请参阅如何:读取和写入文档属性以获取更多信息。
本文收集自互联网,转载请注明来源。
如有侵权,请联系 [email protected] 删除。
我来说两句