I have been working on a simple android app using Xamarin.android for a while, I've just started on mobo development so it's pretty new to me, the thing is my app is supposed to be a login and registration form.
I use a class to get and organize the data in List<T>
, thing is I get null exception here is my code
It is most likely a simple mistake, the weirdest thing is that it was working at some point when I tried to add sth else, didn't work deleted it and then this happened
ty in advance
using System;
using System.Collections.Generic;
using System.Linq;
namespace DemoAppXamarinStu {
public class Datos
{
public static List<string> UsuarioL;//= new List<string>()
static List<string> NombreL;//= new List<string>()
static List<string> ApellidoL;//= new List<string>()
static List<string> EmailL;// = new List<string>()
public static List<string> ContraseñaL;// = new List<string>();
public Datos()
{
UsuarioL = new List<string>();
NombreL = new List<string>();
ApellidoL = new List<string>();
EmailL = new List<string>();
ContraseñaL = new List<string>();
UsuarioL.Add("admin");
ContraseñaL.Add("admin");
NombreL.Add("administrador");
ApellidoL.Add("administrador");
EmailL.Add("admin@admin.com");
}
public static void agregar(string value1, string value2, string value3, string value4, string value5)
{
//Datos d = new Datos();
UsuarioL.Add(value1);
NombreL.Add(value2);
ApellidoL.Add(value3);
EmailL.Add(value4);
ContraseñaL.Add(value5);
}
}
}
oh and also check this out an an exception on a comment