I have a .NET 3.5 (target framework) web application. I have some code that looks like this:
public string LogPath { get; private set; } public string ErrorMsg
Your code is valid - it should work fine. Go in to the property pages of your project and make sure that the "Target Framework" is .NET 3.0 or 3.5.