I have some concerns about using the "Add Service Reference" dialog in Visual Studio 2010.
When I look at the files it generates, they contain references to 4.0.0.0
. However my project is targeted to .NET 3.5. Is this going to be a problem? Or is it just the generation tools using .NET 4.0?
Examples:
configuration.svcinfo
<?xml version="1.0" encoding="utf-8"?>
<configurationSnapshot xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:schemas-microsoft-com:xml-wcfconfigurationsnapshot">
<behaviors />
<bindings>
<binding digest="System.ServiceModel.Configuration.BasicHttpBindingElement, System.ServiceModel, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089:<?xml version="1.0" encoding="utf-16"?><Data hostNameComparisonMode="StrongWildcard" maxBufferSize="65536" messageEncoding="Text" name="BasicHttpBinding_ISiteMembershipService" textEncoding="utf-8" transferMode="Buffered"><readerQuotas maxArrayLength="16384" maxBytesPerRead="4096" maxDepth="32" maxNameTableCharCount="16384" maxStringContentLength="8192" /><security mode="TransportCredentialOnly"><message algorithmSuite="Default" clientCredentialType="UserName" /><transport clientCredentialType="Ntlm" proxyCredentialType="None" realm="" /></security></Data>" bindingType="basicHttpBinding" name="BasicHttpBinding_ISiteMembershipService" />
<binding digest="System.ServiceModel.Configuration.BasicHttpBindingElement, System.ServiceModel, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089:<?xml version="1.0" encoding="utf-16"?><Data hostNameComparisonMode="StrongWildcard" maxBufferSize="65536" messageEncoding="Text" name="BasicHttpBinding_ISiteMembershipService1" textEncoding="utf-8" transferMode="Buffered"><readerQuotas maxArrayLength="16384" maxBytesPerRead="4096" maxDepth="32" maxNameTableCharCount="16384" maxStringContentLength="8192" /><security mode="TransportCredentialOnly"><message algorithmSuite="Default" clientCredentialType="UserName" /><transport clientCredentialType="Ntlm" proxyCredentialType="None" realm="" /></security></Data>" bindingType="basicHttpBinding" name="BasicHttpBinding_ISiteMembershipService1" />
</bindings>
<endpoints>
<endpoint normalizedDigest="<?xml version="1.0" encoding="utf-16"?><Data address="http://aasp2010dev.aa.com:31000/_vti_bin/OBS/SiteMemberships/SiteMembershipService.svc&quot; binding="basicHttpBinding" bindingConfiguration="BasicHttpBinding_ISiteMembershipService" contract="SiteMembershipSvc.ISiteMembershipService" name="BasicHttpBinding_ISiteMembershipService" />" digest="<?xml version="1.0" encoding="utf-16"?><Data address="http://aasp2010dev.aa.com:31000/_vti_bin/OBS/SiteMemberships/SiteMembershipService.svc&quot; binding="basicHttpBinding" bindingConfiguration="BasicHttpBinding_ISiteMembershipService" contract="SiteMembershipSvc.ISiteMembershipService" name="BasicHttpBinding_ISiteMembershipService" />" contractName="SiteMembershipSvc.ISiteMembershipService" name="BasicHttpBinding_ISiteMembershipService" />
</endpoints>
</configurationSnapshot>
Reference.cs
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.1
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
namespace OBS.Solutions.SharePoint.SiteMemberships.SiteMembershipSvc {
using System.Runtime.Serialization;
using System;
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Runtime.Serialization", "4.0.0.0")]
[System.Runtime.Serialization.DataContractAttribute(Name="MembershipCollection", Namespace="OBS.Solutions.SharePoint.SiteMemberships")]
[System.SerializableAttribute()]
public partial class MembershipCollection : object, System.Runtime.Serialization.IExtensibleDataObject, System.ComponentModel.INotifyPropertyChanged {
...