.NET DLL conflict

I made a test program for some Sharepoint WSS3 features, but I came across an odd exception.

public XmlNode GetListsCollection()
{
    XmlNode nodeLists;

    ShareLists.Lists lists = new ShareLists.Lists(); // <--- Exception causing line
    lists.Credentials = CredentialCache.DefaultCredentials;

    return nodeLists = lists.GetListCollection();
}

// An exception is displayed here (Settings.Designer.cs)

[global::System.Configuration.ApplicationScopedSettingAttribute()]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Configuration.SpecialSettingAttribute(global::System.Configuration.SpecialSetting.WebServiceUrl)]
[global::System.Configuration.DefaultSettingValueAttribute("http://uk-tr-dsf/_vti_bin/Lists.asmx")]
public string SharepointWeb_ShareLists_Lists {
    get {
        return ((string)(this["SharepointWeb_ShareLists_Lists"]));
    }
}

This error occurred when I changed my project from .NET 4 to .NET 3.5, which was necessary to fix the "PlatformNotSupportException".

Therefore, I cannot change it.

System.Configuration.ConfigurationErrorsException was unhandled
  Message=An error occurred creating the configuration section handler for applicationSettings/SharepointWeb.Properties.Settings: Could not load file or assembly 'System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' or one of its dependencies. The system cannot find the file specified. (C:\Working\SharepointPlugin\SharepointWeb\bin\Debug\SharepointWeb.vshost.exe.Config line 5)
  Source=System.Configuration
  BareMessage=An error occurred creating the configuration section handler for applicationSettings/SharepointWeb.Properties.Settings: Could not load file or assembly 'System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' or one of its dependencies. The system cannot find the file specified.
  Filename=C:\Working\SharepointPlugin\SharepointWeb\bin\Debug\SharepointWeb.vshost.exe.Config
  Line=5
  Stacktrace: ... omitted

I understand that this ConfigurationErrorsExceptionis a delegate, and the real exception message is an internal exception.

System.IO.FileNotFoundException
           Message=Could not load file or assembly 'System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' or one of its dependencies. The system cannot find the file specified.

Now this file has been found and is clearly present in my links, but it is Microsoft.CSharpmissing (due to the fact that it is a .NET 3.5 project) Will I correctly assume that this is the reason? Is there a version for Frameworks in .NET 4? I have looked C:\Program Files\Reference Assemblies\Microsoft\Framework\.NETFramework\and cannot see the equivalent version.


Decision:

They had to be changed.

resx:

  <resheader name="reader">
    <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
  </resheader>
  <resheader name="writer">
    <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
  </resheader>

app.config:

<configSections>
    <sectionGroup name="applicationSettings" type="System.Configuration.ApplicationSettingsGroup, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
        <section name="SharepointWeb.Properties.Settings" type="System.Configuration.ClientSettingsSection, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false"/>
    </sectionGroup>
</configSections>
+3
2

Microsoft.CSharp.dll 3.5, 4.0 ( , , 4.0), .

4 system.dll, , . , 3.5, system.dll 2.0, 4 system.dll Framework 4

, , dll 4.

+5

, . 2.0-3.5, 4.0. , Framework, , , 4.0.

+1

All Articles