Click here to Skip to main content
15,113,873 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
Good Afternoon everybody !!!.

A question: What for do you add a XML file to a vb Net project ?. What's its use or advantages in doing that ?

What I have tried:

Search thru internet for many times, and I still can´t find a specific answer to that; all pages I've seen talks about how to do it etc... but nothing about this.

It´s like I need a comment from a programmer.
Posted
Updated 24-May-18 10:48am
v2
Comments
Maciej Los 23-May-18 16:28pm
   
Miguel, could you be more specific? No one here is able to read in your mind...
What's for you need this xml file?
Miguel Altamirano Morales 24-May-18 10:34am
   
I meant: why a programmer should add a new element "XML file" to a Visual Studio project ?, to do what ?.

What is the utility or advantage of adding an xml file to a project ?. What can a programmer do by adding this kind of file to a project.

Pleas forgive me if I don´t make my self clear. English is not my native language, and sometimes I turn to the google translator expecting to be able to convey what I intent to say.

Maybe this was the case, but you don´t have to take care of this if I cannot explain myself again.

Maciej Los 24-May-18 15:43pm
   
Some xml files are added automatically by VS... They are used to store specific data, for example comments to the code, see: Documenting your code with XML comments | Microsoft Docs[^]. Other files may contain project settings, etc. Finally, some xml files might be used to store data. Xml data can be "converted" into objects. See my answer, please.
Miguel Altamirano Morales 25-May-18 10:43am
   
Thank you very much Maciej; Nice to meet you again.

Yes, I'll carefully study what you are suggesting me.

Greetings.
Maciej Los 25-May-18 11:20am
   
You're very welcome.
Cheers,
Maciej

1 solution

Seems, you're talking about XmlSerialization[^].

MSDN documentation states:
Serialization is the process of converting an object into a form that can be readily transported. For example, you can serialize an object and transport it over the Internet using HTTP between a client and a server. On the other end, deserialization reconstructs the object from the stream.


For further details, please see:
XML Serialization in the .NET Framework[^]
XML Serialization – Tips & Tricks[^]
XML Serialization and Deserialization: Part-1[^]
XML Serialization and Deserialization: Part-2[^]
A Complete Sample of Custom Class Collection Serialization and Deserialization[^]
   

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)




CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900