I created a Web Service: I imported System.Data.SqlClient so I could
access SQL server tables programmatically. The web service builds and
deploys with no problems. When I try to add the corresponding Web
Reference to the Web Site project I get the error listed below.
I am able to create other Web Services on the same server and I am able
to add Web Referneces to them. I have narrowed it down to the "Imports
System.Data.SqlClient" statement, I think. What's up with this?
I changed tempuri.org to something I have control over and it had no
effect.
Thanks,
Bill
Cincinnati, OH USA
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
Server Error in '/foo' Application.
--------------------------------------------------------------------------------
The XML element 'EnableTheming' from namespace 'http://tempuri.org/' is
already present in the current scope. Use XML attributes to specify
another XML name or namespace for the element.
Description: An unhandled exception occurred during the execution of
the current web request. Please review the stack trace for more
information about the error and where it originated in the code.
Exception Details: System.InvalidOperationException: The XML element
'EnableTheming' from namespace 'http://tempuri.org/' is already present
in the current scope. Use XML attributes to specify another XML name or
namespace for the element.
Source Error:
An unhandled exception was generated during the execution of the
current web request. Information regarding the origin and location of
the exception can be identified using the exception stack trace below.
Stack Trace:
[InvalidOperationException: The XML element 'EnableTheming' from
namespace 'http://tempuri.org/' is already present in the current
scope. Use XML attributes to specify another XML name or namespace for
the element.]
System.Xml.Serialization.XmlReflectionImporter.Add UniqueAccessor(INameScope
scope, Accessor accessor) +771933
System.Xml.Serialization.XmlReflectionImporter.Add UniqueAccessor(MemberMapping
member, INameScope elements, INameScope attributes, Boolean isSequence)
+88
System.Xml.Serialization.XmlReflectionImporter.Imp ortStructLikeMapping(StructModel
model, String ns, Boolean openModel, XmlAttributes a) +2097
[InvalidOperationException: There was an error reflecting property
'EnableTheming'.]
System.Xml.Serialization.XmlReflectionImporter.Imp ortStructLikeMapping(StructModel
model, String ns, Boolean openModel, XmlAttributes a) +2693
System.Xml.Serialization.XmlReflectionImporter.Imp ortStructLikeMapping(StructModel
model, String ns, Boolean openModel, XmlAttributes a) +791
System.Xml.Serialization.XmlReflectionImporter.Imp ortTypeMapping(TypeModel
model, String ns, ImportContext context, String dataType, XmlAttributes
a, Boolean repeats, Boolean openModel) +638
[InvalidOperationException: There was an error reflecting type
'System.Web.UI.Page'.]
System.Xml.Serialization.XmlReflectionImporter.Imp ortTypeMapping(TypeModel
model, String ns, ImportContext context, String dataType, XmlAttributes
a, Boolean repeats, Boolean openModel) +1533
System.Xml.Serialization.XmlReflectionImporter.Imp ortAccessorMapping(MemberMapping
accessor, FieldModel model, XmlAttributes a, String ns, Type
choiceIdentifierType, Boolean rpc, Boolean openModel) +11213
System.Xml.Serialization.XmlReflectionImporter.Imp ortFieldMapping(StructModel
parent, FieldModel model, XmlAttributes a, String ns) +136
System.Xml.Serialization.XmlReflectionImporter.Imp ortStructLikeMapping(StructModel
model, String ns, Boolean openModel, XmlAttributes a) +1824
[InvalidOperationException: There was an error reflecting property
'Page'.]
System.Xml.Serialization.XmlReflectionImporter.Imp ortStructLikeMapping(StructModel
model, String ns, Boolean openModel, XmlAttributes a) +2693
System.Xml.Serialization.XmlReflectionImporter.Imp ortStructLikeMapping(StructModel
model, String ns, Boolean openModel, XmlAttributes a) +791
System.Xml.Serialization.XmlReflectionImporter.Imp ortStructLikeMapping(StructModel
model, String ns, Boolean openModel, XmlAttributes a) +791
System.Xml.Serialization.XmlReflectionImporter.Imp ortStructLikeMapping(StructModel
model, String ns, Boolean openModel, XmlAttributes a) +791
System.Xml.Serialization.XmlReflectionImporter.Imp ortStructLikeMapping(StructModel
model, String ns, Boolean openModel, XmlAttributes a) +791
System.Xml.Serialization.XmlReflectionImporter.Imp ortStructLikeMapping(StructModel
model, String ns, Boolean openModel, XmlAttributes a) +791
System.Xml.Serialization.XmlReflectionImporter.Imp ortTypeMapping(TypeModel
model, String ns, ImportContext context, String dataType, XmlAttributes
a, Boolean repeats, Boolean openModel) +638
[InvalidOperationException: There was an error reflecting type
'System.Web.UI.WebControls.ListBox'.]
System.Xml.Serialization.XmlReflectionImporter.Imp ortTypeMapping(TypeModel
model, String ns, ImportContext context, String dataType, XmlAttributes
a, Boolean repeats, Boolean openModel) +1533
System.Xml.Serialization.XmlReflectionImporter.Imp ortAccessorMapping(MemberMapping
accessor, FieldModel model, XmlAttributes a, String ns, Type
choiceIdentifierType, Boolean rpc, Boolean openModel) +11213
System.Xml.Serialization.XmlReflectionImporter.Imp ortMemberMapping(XmlReflectionMember
xmlReflectionMember, String ns, XmlReflectionMember[]
xmlReflectionMembers, Boolean rpc, Boolean openModel) +977
System.Xml.Serialization.XmlReflectionImporter.Imp ortMembersMapping(XmlReflectionMember[]
xmlReflectionMembers, String ns, Boolean hasWrapperElement, Boolean
rpc, Boolean openModel) +278
[InvalidOperationException: There was an error reflecting 'pListBox'.]
System.Xml.Serialization.XmlReflectionImporter.Imp ortMembersMapping(XmlReflectionMember[]
xmlReflectionMembers, String ns, Boolean hasWrapperElement, Boolean
rpc, Boolean openModel) +877
System.Xml.Serialization.XmlReflectionImporter.Imp ortMembersMapping(String
elementName, String ns, XmlReflectionMember[] members, Boolean
hasWrapperElement, Boolean rpc, Boolean openModel, XmlMappingAccess
access) +111
System.Web.Services.Protocols.SoapReflector.Import MembersMapping(XmlReflectionImporter
xmlImporter, SoapReflectionImporter soapImporter, Boolean
serviceDefaultIsEncoded, Boolean rpc, SoapBindingUse use,
SoapParameterStyle paramStyle, String elementName, String
elementNamespace, Boolean nsIsDefault, XmlReflectionMember[] members,
Boolean validate, Boolean openModel, String key, Boolean writeAccess)
+203
System.Web.Services.Protocols.SoapReflector.Reflec tMethod(LogicalMethodInfo
methodInfo, Boolean client, XmlReflectionImporter xmlImporter,
SoapReflectionImporter soapImporter, String defaultNs) +2460
[InvalidOperationException: Method Service.LoadListBox can not be
reflected.]
System.Web.Services.Protocols.SoapReflector.Reflec tMethod(LogicalMethodInfo
methodInfo, Boolean client, XmlReflectionImporter xmlImporter,
SoapReflectionImporter soapImporter, String defaultNs) +6904
System.Web.Services.Description.SoapProtocolReflec tor.ReflectMethod()
+133
System.Web.Services.Description.ProtocolReflector. ReflectBinding(ReflectedBinding
reflectedBinding) +2760
System.Web.Services.Description.ProtocolReflector. Reflect() +739
System.Web.Services.Description.ServiceDescription Reflector.ReflectInternal(ProtocolReflector[]
reflectors) +621
System.Web.Services.Description.ServiceDescription Reflector.Reflect(Type
type, String url) +117
System.Web.Services.Protocols.DocumentationServerT ype..ctor(Type
type, String uri) +159
System.Web.Services.Protocols.DocumentationServerP rotocol.Initialize()
+336
System.Web.Services.Protocols.ServerProtocolFactor y.Create(Type
type, HttpContext context, HttpRequest request, HttpResponse response,
Boolean& abortProcessing) +99
[InvalidOperationException: Unable to handle request.]
System.Web.Services.Protocols.ServerProtocolFactor y.Create(Type
type, HttpContext context, HttpRequest request, HttpResponse response,
Boolean& abortProcessing) +258
System.Web.Services.Protocols.WebServiceHandlerFac tory.CoreGetHandler(Type
type, HttpContext context, HttpRequest request, HttpResponse response)
+90
[InvalidOperationException: Failed to handle request.]
System.Web.Services.Protocols.WebServiceHandlerFac tory.CoreGetHandler(Type
type, HttpContext context, HttpRequest request, HttpResponse response)
+237
System.Web.Services.Protocols.WebServiceHandlerFac tory.GetHandler(HttpContext
context, String verb, String url, String filePath) +104
System.Web.HttpApplication.MapHttpHandler(HttpCont ext context,
String requestType, VirtualPath path, String pathTranslated, Boolean
useAppConfig) +175
System.Web.MapHandlerExecutionStep.System.Web.Http Application.IExecutionStep.Execute()
+120
System.Web.HttpApplication.ExecuteStep(IExecutionS tep step, Boolean&
completedSynchronously) +155
--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:2.0.50727.42;
ASP.NET Version:2.0.50727.42