I have recently got an intern project. In this task, I must assign unique IDs to OpenXML files used by Microsoft Office 2010. I have so far attempted a lot of ways of doing it. But all failed. I use visual studio 2010. Do you have any idea what methods and classes I have to use to assign a unique ID to a file with C#? If you give me any example with C# code, I would appreciate it.
This isn't quite clear to me. Are you having difficulty creating the unique ID or having trouble storing it in the OpenXML file? You can generate a unique ID as a GUID:
id = Guid.NewGuid();
I hope that helps.
Thanks. It helps me how to add something to an xml document. I will try it and ask you another question.
I found an example of xsd:ID on the net.
<xsd:simpleType name="ID" id="ID">
they say this code is a general synopsis. Whatever.. Do you how to add a string value to this formula? and Can I use it for MS OFFICE 2010 xml files?