I want to do a uipickerview with three columns, but only the first appears loaded other empty, I can not find the error if someone knows how to solve thank you. Here is the code:
staticstring[]nomesPeso=newstring[]{"Back Squat",
"Front Squat",
"OHS - Overhead Squat"
};
static string[] nomesUnidades = new string[]
{
"Reps",
"Kgs",
"Lbs",
"Metros"
};
static string[] nomesRepeticoes = new string[]
{
"1 RM",
"2 RM",
"3 RM"
};
public override nint GetComponentCount(UIPickerView v)
{
return 3;
}
public override nint GetRowsInComponent(UIPickerView pickerView, nint component)
{
switch (component)
{
case 0:
return nomesPeso.Length;
case 1:
return nomesRepeticoes.Length;
case 2:
return nomesUnidades.Length;
default:
throw new NotImplementedException();
}
}
public override string GetTitle(UIPickerView picker, nint row, nint component)
{
switch (component)
{
case 0:
return nomesPeso[row];
case 1:
return nomesRepeticoes[row];
case 2:
return nomesUnidades[row];
default:
throw new NotImplementedException();
}
}