How can assign NavigationPage.TitleView to a ContentView?
No, you can't.
TitleView is an attached property of the navigation page. It can be set to any page embedded into the navigation page:https://docs.microsoft.com/en-us/xamarin/xamarin-forms/app-fundamentals/navigation/hierarchical#displaying-views-in-the-navigation-bar
But it can't be applied to a content view. And the content view must be used on a content page. You should manipulate the content page directly instead of the content view.
Xamarin Inc., as a wholly-owned Microsoft subsidiary acting as a separate legal entity, adheres to the Microsoft Privacy Statement: Privacy & cookies