CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1
    Join Date
    Jun 2011
    Posts
    1

    Unhappy Error when opening XSD file in XML spy

    hi,

    I have an XSD file and tried to open that MasterFile.xsd using XML spy and it throws error that the

    Included/imported schema file "c:\dir1\CodeCntr.xsd" has a different target namespace .

    Expected "http://www.coderEx1.com/schemas/2011/07.sm"
    Found "http://www.coderEx1.com/schemas/2004/06.sm"

    In my MasterFile.xsd I have a namespace declared
    xmlns:grpz = "http://www.coderEx1.com/schemas/2011/07.sm"

    and in the CodeCntr.xsd I have
    xmlns="http://www.coderEx1.com/schemas/2004/06.sm"

    how do I resolve this? .

    Thanks
    SL

  2. #2
    Join Date
    Jun 2011
    Posts
    6

    Re: Error when opening XSD file in XML spy

    do you also have the targetNamespace attribute defined in your schemas?

  3. #3
    Join Date
    Jun 2011
    Posts
    6

    Re: Error when opening XSD file in XML spy

    Quote Originally Posted by SmartLearner View Post
    hi,

    I have an XSD file and tried to open that MasterFile.xsd using XML spy and it throws error that the

    Included/imported schema file "c:\dir1\CodeCntr.xsd" has a different target namespace .

    Expected "http://www.coderEx1.com/schemas/2011/07.sm"
    Found "http://www.coderEx1.com/schemas/2004/06.sm"

    In my MasterFile.xsd I have a namespace declared
    xmlns:grpz = "http://www.coderEx1.com/schemas/2011/07.sm"

    and in the CodeCntr.xsd I have
    xmlns="http://www.coderEx1.com/schemas/2004/06.sm"

    how do I resolve this? .

    Thanks
    SL
    CodeCntr.xsd defines the "default namespace" this is not the same as target namespace.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured