SharpDevelop Community

Get your problems solved!
Welcome to SharpDevelop Community Sign in | Join | Help
in Search

Error importing WSDL file

Last post 03-27-2007 11:14 PM by MattWard. 3 replies.
Page 1 of 1 (4 items)
Sort Posts: Previous Next
  • 03-02-2007 3:03 PM

    Error importing WSDL file

    1 - right-click "project"

    2 - "add web-reference"

    3 - navigate to a web-service address

    4 - navigate to the web-service WSDL

    5 - when WSDL is displayed, confirm the import

    6 - bug:

    SharpDevelop Version : 2.1.0.2409
    .NET Version         : 2.0.50727.42
    OS Version           : Microsoft Windows NT 5.1.2600 Service Pack 2
    Current culture      : Italian (Italy) (it-IT)
    Working Set Memory   : 79612kb
    GC Heap Memory       : 16955kb

    Exception thrown:
    System.InvalidOperationException: Initialization failure. Please review input options and documents for validity. ---> System.ArgumentException: The type name:"Tests.10.139.8.27" on the property:"Name" of type:"System.CodeDom.CodeNamespace" is not a valid language-independent type name.
    Parameter name: typeName
       at System.CodeDom.Compiler.CodeValidator.ValidateTypeName(Object e, String propertyName, String typeName)
       at System.CodeDom.Compiler.CodeValidator.ValidateNamespaceStart(CodeNamespace e)
       at System.CodeDom.Compiler.CodeValidator.ValidateIdentifiers(CodeObject e)
       at System.CodeDom.Compiler.CodeGenerator.ValidateIdentifiers(CodeObject e)
       at System.Xml.Serialization.CodeExporter..ctor(CodeNamespace codeNamespace, CodeCompileUnit codeCompileUnit, CodeDomProvider codeProvider, CodeGenerationOptions options, Hashtable exportedMappings)
       at System.Xml.Serialization.XmlCodeExporter..ctor(CodeNamespace codeNamespace, CodeCompileUnit codeCompileUnit, CodeDomProvider codeProvider, CodeGenerationOptions options, Hashtable mappings)
       at System.Web.Services.Description.SoapProtocolImporter.BeginNamespace()
       --- End of inner exception stack trace ---
       at System.Web.Services.Description.SoapProtocolImporter.BeginNamespace()
       at System.Web.Services.Description.ProtocolImporter.GenerateCode(CodeNamespace codeNamespace, ImportContext importContext, Hashtable exportContext)
       at System.Web.Services.Description.ServiceDescriptionImporter.Import(CodeNamespace codeNamespace, ImportContext importContext, Hashtable exportContext, StringCollection warnings)
       at System.Web.Services.Description.ServiceDescriptionImporter.Import(CodeNamespace codeNamespace, CodeCompileUnit codeCompileUnit)
       at ICSharpCode.SharpDevelop.Gui.WebReference.GenerateWebProxy(String proxyNamespace, String fileName, ServiceDescriptionCollection serviceDescriptions, XmlSchemas schemas)
       at ICSharpCode.SharpDevelop.Gui.WebReference.GenerateWebProxy()
       at ICSharpCode.SharpDevelop.Gui.WebReference.Save()
       at ICSharpCode.SharpDevelop.Project.Commands.AddWebReferenceToProject.Run()
       at ICSharpCode.Core.MenuCommand.OnClick(EventArgs e)
       at System.Windows.Forms.ToolStripItem.HandleClick(EventArgs e)
       at System.Windows.Forms.ToolStripItem.HandleMouseUp(MouseEventArgs e)
       at System.Windows.Forms.ToolStripItem.FireEventInteractive(EventArgs e, ToolStripItemEventType met)
       at System.Windows.Forms.ToolStripItem.FireEvent(EventArgs e, ToolStripItemEventType met)
       at System.Windows.Forms.ToolStrip.OnMouseUp(MouseEventArgs mea)
       at System.Windows.Forms.ToolStripDropDown.OnMouseUp(MouseEventArgs mea)
       at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
       at System.Windows.Forms.Control.WndProc(Message& m)
       at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
       at System.Windows.Forms.ToolStrip.WndProc(Message& m)
       at System.Windows.Forms.ToolStripDropDown.WndProc(Message& m)
       at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
       at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
       at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
     

    Filed under:
  • 03-02-2007 4:27 PM In reply to

    Re: Error importing WSDL file

    We would need to see the WSDL to work out what the problem is. At first glance it would seem that the .NET Framework does not like the WSDL. You could try Microsoft's Wsdl.exe and see if it throws the same error. If it fails to generate the client proxy then the WSDL would need to be modified.
  • 03-27-2007 10:26 AM In reply to

    Re: Error importing WSDL file

    I've already checked the WSDL. I tried to import it manually by submitting it to Microsoft's wsdl.exe (.NET 2.0) and the proxy generation succeded without any errors or warnings.

    The detail of the error I've submitted shows that the problem is in the CodeDom namespace. It seems that this namespace raises an error that #Develop can't handle. ("Initialization failure. Please review input options and documents for validity. ---> System.ArgumentException: The type name:"Tests.10.139.8.27" on the property:"Name" of type:"System.CodeDom.CodeNamespace" is not a valid language-independent type name.").

    I think it occurs because of the "Tests.10.139.8.27" string I submitted to #Develop "new WebReference" form, in the text-box "Reference name" or in the "Namespace" one.

     

    Nicola Orritos

  • 03-27-2007 11:14 PM In reply to

    Re: Error importing WSDL file

    Added a bug report.

    I think the only thing we can do is validate the namespace and show a more user friendly error message. 

Page 1 of 1 (4 items)
Powered by Community Server (Commercial Edition), by Telligent Systems
Don't contact us via this (fleischfalle@alphasierrapapa.com) email address.