Home › Forums › Bunifu UI Winforms › Invoice System Tutorial Question
Tagged: SQL
-
AuthorPosts
-
-
Good Afternoon,
I have a question about the video posted by KIMTOOFLEX. I followed the tutorial from the Bunifu Invoice System and I cant get my code to search for in the client table. It looks just like the code in the video and I always get no results. Your help would be greatly appreciatedThis is the video I’m referring to
Here is my code:
void loadClients() { gridClient.Rows.Clear(); List<Models.Client> clients = BunifuMapper.MapToList<Models.Client>(db.GetRows("select * from clients where 'ClientName' LIKE '%" + txtSearch.Text.Trim() + "%'")); foreach (var client in clients) { gridClient.Rows.Add(new object[] { client.id, client.ClientName, client.Address, client.PostalCode, client.Country, client.City }); gridClient.Rows[gridClient.RowCount - 1].Tag = client; } }
-
I don’t know why my code didn’t come out right above. Here it is again in plain text:
void loadClients()
{gridClient.Rows.Clear();
List<Models.Client> clients = BunifuMapper.MapToList<Models.Client>(db.GetRows(“select * from clients where ‘ClientName’ LIKE ‘%” + txtSearch.Text.Trim() + “%'”));foreach (var client in clients)
{
gridClient.Rows.Add(new object[] {
client.id,
client.ClientName,
client.Address,
client.PostalCode,
client.Country,
client.City
});gridClient.Rows[gridClient.RowCount – 1].Tag = client;
}
}
-
-
AuthorPosts
- You must be logged in to reply to this topic.