Hi,
in order to use LINQ to XSD make sure you are using the latest version i.e. do not use any of the Preview Alphaversions.LINQ to XSD was recently released on CodePlex [1].
You need to follow a few steps to make LINQ to XSD work for your project.
1. Start the 'Visual Studio 2008 Command Prompt' from the start menu.
2. If not done so far, create a directory that will contain your LinqToXsd binaries (e.g. c:\LinqToXsdBin)
3. Type 'SET LINQTOXSDBINDIR=C:\LINQTOXSDBIN' (replace with the path you have chosen from 2.)
4. Start Visual Studio from within the command prompt (type 'devenv.exe'). That's the reason we started the 'Visual Studio 2008 Command Propmt'.
5. Open the XObjects.sln solution file from the LinqToXsd project and compile. The binaries will be dropped to the directory you specified before
using the environmental variable LINQTOXSDBINDIR.
6. Open your own project/solution. It is very important that you open your project/solution from the Visual Studio instance that was started from the command prompt where the LINQTOXSDBINDIR variable was defined. That way Visual Studio will be able to pick up the build tasks. If you have already compiled LinqToXsd, you can skip step 5, but not the steps before.
7. Before you can use the build tasks, you have to prepare your project file. Right click the project in Solution Explorer at select 'Unload Project'.
8. Right click the project (unloaded) again and select 'Edit [YourProjectFileName].csproj'. The project file will be opened in the Visual Studio XML text editor.
9. Navigate to the end of the file. Now add the following lines into the project file below the last 'PropertyGroup':
<PropertyGroup>
<LinqToXsdBinDir Condition="'$(LinqToXsdBinDir)' == ''">$(SolutionDir)</LinqToXsdBinDir>
</PropertyGroup>
10. Now navigate to the very end of the file below the very last and insert the following lines after the very last 'Import'. Enter the following line. It is very important that this line is located after all other import statements.
<Import Project="$(LinqToXsdBinDir)\LinqToXsd.targets" />
11. Right click your project and select 'Reload Project.
Now you should be able to select LinqToXsdSchema from as build action for your XSD file.
I assume the option might not be shown in your project as Visual Studio was not started in the proper context with the LINQTOXSDBINDIR environmental variable defined (e.g. started from a shortcut).
The previously described steps should work for both, Visual Studio 2008 and Visual Studio 2010. In order to you Visual Studio 2010 you have to start the 'Visual Studio 2010 Command Propmpt' instead.
Andreas