In Visual Studio it is possible to paste the XML file’s content as Classes. But I needed something to parse several XML files to their corresponding C# Classes. And to do that you can also use the xsd.exe tool.
So in short, use the following example batch file to generate the classes you need.
@ECHO OFF
REM Date: 22-feb-2022
REM Author: botten@mprise.nl
REM Description: Convert XML file to C# Class
SET XSD="c:\Program Files (x86)\Microsoft SDKs\Windows\v10.0A\bin\NETFX 4.6.1 Tools\xsd.exe"
SET SOURCE="d:\Temp\xml\My-Quiz.xml"
%XSD% %SOURCE%
pause