Entity Framework - Unable to load the specified metadata resource

前端 未结 17 1287
一生所求
一生所求 2020-12-14 15:21

I realise that this has been asked a number of times but I just can\'t seem to get the bottom of my issue. I\'m getting the following error stack:

17条回答
  •  星月不相逢
    2020-12-14 15:48

    If you're trying to use more than one EDMX file and you have to put your new EDMX file in it's own namespace due to conflicts, when creating the EDMX file take note of the metadata the wizard shows you. That one is the correct one.

    Then later if you are using EntityConnectionStringBuilder and are setting the Metadata there make sure you take into account the new namespace.

    None of the answers here helped me as I had: /EDMX1 /Namespace/EDMX2

    and while the metadata for the EDMX1 is "edmx1.csdl|edmx1.ssdl|edmx1.msl" The metadata for EDMX2 is "Namespace.edmx2.csdl ..."

提交回复
热议问题