I want to display the content of a sqlite table to look something like this:
so far i have this:
public void printHighscores()
{
connectToDatabase();
string sql = "select * from Pacientes";
SQLiteCommand command = new SQLiteCommand(sql, m_dbConnection);
SQLiteDataReader reader = command.ExecuteReader();
int a = 0;
while (reader.Read())
{
//Console.WriteLine("Name: " + reader["nombre"] + "\tEmail: " + reader["correo"] + "PEso: " + reader["peso"]);
System.Windows.Controls.Button newBtn = new Button();
a++;
newBtn.Content = reader["nombre"];
newBtn.Name = "Button" + a;
Wrapsito.Children.Add(newBtn);
}
m_dbConnection.Close();
}
and the display its this:
Any tutorial, metod, workaround would be highly wanted =) Thanks in advance
Aucun commentaire:
Enregistrer un commentaire