datagrid を使用して、sqlite に接続しています。sqlite の特定のテーブルをデータ グリッドで開くことができます。しかし今、テーブルから特定のものを検索したいのですが、select ステートメントを使用してテキスト ボックスを適用しています。ユーザーは入力を入力し、そこから検索します。以下は私のコードです
private void button2_Click(object sender, EventArgs e)
{
SQLiteConnection connection2 = new SQLiteConnection(@"Data Source = C:\ssds\WEBATM\APTRABuilder.sqlite;Version =3");
connection2.Open();
string sql2 = "Select *from builderScreenResourceBundleTBL where screenId like '%_textboxSearch%'";
SQLiteDataAdapter connect2 = new SQLiteDataAdapter(sql2, connection2);
DataSet ds2 = new DataSet();
connect2.Fill(ds2);
dataGridView.DataSource = ds2.Tables[0];
}
では、sql2 文字列ステートメントでは、テキスト ボックスからどのように入力する必要がありますか?