DaClownie
NullReferenceException but checking for Null?
I click a button on my .NET MAUI UI to Create a new course. ContentPage loads, I enter my information. If I leave any of the entry fields blank, the program crashes... stating
System.NullReferenceException Message=Object reference not set to an instance of an object.
23 replies
New ContentPages in .net MAUI app don't have InitializeComponent() methods
I'm following a few guides to learn how to do Navigation in a .NET MAUI app which I need to apply for a project for school. All of the guides show creation of multiple ContentPages, assigning it as such in
App.xaml.cs
I created a new ContentPage in the solution named TermPage
but it doesn't have a InitializeComponent()
and I'm unable to Build my project and send it to the Android Emulator. How come the guides have no issue with the creation of the InitializeComponent()
method and mine does? And How do I fix it?17 replies