wpf - How i can use combobox.selectedvalue in SQL query in C#? -
this question has answer here:
how can use combobox.selectedvalue
in sql query in c#?
using (oracledb db = new oracledb()) { if (name.checked) { datatable namedt= db.select("select name people name= in place need selected value combobox1"), "osoby"); } }
using (oracledb db = new oracledb()) { if (name.checked) { var sql = string.format("select [name] people [name] = {0}", combobox1.selecteditem.tostring()) var namedt = db.select(sql, "osoby"); } }
Comments
Post a Comment