IN:
Hi, I have a drop down list and I am getting two errors.
Mistake # 1: My requirement is to select a meeting name from the drop-down list, save it to a string, and use that string later. I want to get the value of a field (which gives me the path where the files are stored) from the database table.
Code:
string selected = DropDownList1.SelectedValue.ToString(); var query = from meet in db.Meets where meet.Summary = selected select meet.Doc_Path;
I get the error " where meet.Summary=selected
" and it says
"cannot implicitly convert a string of type to bool"
Mistake # 2: I want to use the Doc_Path
value that I get through the request. I am not sure about the syntax and therefore get an error message when I tried it.
Code:
string[] dirs = Directory.GetDirectories(query);
Please, help.
source share