WPF: Unable to locate resources in my namespaces in XAML code

y’all. This is a tricky problem that I’ve encountered. I’ve picked up an existing repository with some especially sloppy WPF that doesn’t adhere to MVVM best practices at all. I plan to refactor, but I have near term release targets I want to hit. So, until then, I’m going to follow best practices.

Here’s the rub, if I make any user control, converter, etc, I am unable to reference them in any xaml whatsoever. Suppose I have a window:

<Window … xmlns:views=“clr-namespace:PCXperience.Views” … > 
    <Window.Resources>
        <views:MyUserControl x:Key=“MyUserControl”/>
    </Window.Resources>
    …
    <views:MyUserControl/>
</Window>
    ```

This is a simple version of the issue. I’ll get xaml errors that the namespace doesn’t exist … it does. And I’ll get an error on the line with the UserControl saying that MyUserControl does not exist in the namespace. 

**What I’ve done so far.**

I’ve checked, double checked and triple checked that the namespace is correct. I’ve set the Build Action of the user control to Page and CopyIfNewer. I’ve checked thoroughly that I have the correct Attributes on both the Window and the UserControl. I have cleaned my solution, saved the code, deleted the .vs folder, deleted the obj folder, deleted the bin folder, closed the solution, reopened the solution and done Rebuild Solution. I have even copied the code — everything within the Window and UserControl tabs, their code behinds, and such and pasted into a new repo. The code works in another repo.

**Areas that I suspect** 
The declaration attributes of the Window and UserControl could still be wrong somehow though I can’t see it.
The Solution/Project/Etc files could have some error that prevents them from recognizing files in their respective name spaces but it seems to only affect xaml. I can correctly make these in the code behind if I have to, but I don’t want to. 
It’s possible some silly issue that I’ve repeatedly overlooked. 

I am able to use my resource dictionaries in my project — I just can’t declare new resources in my XAMLs whatsoever. 

In an act of what can only be described as a masochistic need for punishment, I wrote this post on my phone. I’ll edit the post to include the top level declarations for each View Element in a moment so we can look at them and see if I’ve missed something obvious. But I am not prepared to type them on my phone here, for the initial post because… I guess that’s where I draw the line, lol. 

Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa Dịch vụ tổ chức sự kiện 5 sao Thông tin về chúng tôi Dịch vụ sinh nhật bé trai Dịch vụ sinh nhật bé gái Sự kiện trọn gói Các tiết mục giải trí Dịch vụ bổ trợ Tiệc cưới sang trọng Dịch vụ khai trương Tư vấn tổ chức sự kiện Hình ảnh sự kiện Cập nhật tin tức Liên hệ ngay Thuê chú hề chuyên nghiệp Tiệc tất niên cho công ty Trang trí tiệc cuối năm Tiệc tất niên độc đáo Sinh nhật bé Hải Đăng Sinh nhật đáng yêu bé Khánh Vân Sinh nhật sang trọng Bích Ngân Tiệc sinh nhật bé Thanh Trang Dịch vụ ông già Noel Xiếc thú vui nhộn Biểu diễn xiếc quay đĩa Dịch vụ tổ chức tiệc uy tín Khám phá dịch vụ của chúng tôi Tiệc sinh nhật cho bé trai Trang trí tiệc cho bé gái Gói sự kiện chuyên nghiệp Chương trình giải trí hấp dẫn Dịch vụ hỗ trợ sự kiện Trang trí tiệc cưới đẹp Khởi đầu thành công với khai trương Chuyên gia tư vấn sự kiện Xem ảnh các sự kiện đẹp Tin mới về sự kiện Kết nối với đội ngũ chuyên gia Chú hề vui nhộn cho tiệc sinh nhật Ý tưởng tiệc cuối năm Tất niên độc đáo Trang trí tiệc hiện đại Tổ chức sinh nhật cho Hải Đăng Sinh nhật độc quyền Khánh Vân Phong cách tiệc Bích Ngân Trang trí tiệc bé Thanh Trang Thuê dịch vụ ông già Noel chuyên nghiệp Xem xiếc khỉ đặc sắc Xiếc quay đĩa thú vị
Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa
Thiết kế website Thiết kế website Thiết kế website Cách kháng tài khoản quảng cáo Mua bán Fanpage Facebook Dịch vụ SEO Tổ chức sinh nhật