This is a known issue, especially with Windows Vista, resulting in the following message:
There was an error in serializing body of message : 'Unable to generate a temporary class (result = 1).
error CS2001: Source File 'C:\Windows\TEMP\...' could not be found
error CS2008: No imports specified
'. Please see InnerException for more details.
If you see this error, the resolution is simple:
- Open Windows Explorer and navigate to the C:\Windows directory.
- Right click on the TEMP folder, and select the Security tab
- Click on the Advanced button at the bottom right
- Under the Permissions tab, select the Users permission entry in the list, and click Edit.
- If you don't see a list, but a Continue button, click it first
- In the permission entry dialog, allow the users Write and Delete on the directory, click OK, and confirm any warnings until you reach the security settings dialog again.
- In the security settings dialog, be sure to select the 'Replace all child object permission entries' check box at the bottom, and click OK, confirming any warnings.