Click here to Skip to main content
15,867,488 members
Please Sign up or sign in to vote.
2.00/5 (1 vote)
See more:
i have table with columns empid, empname,empmanagerid, now if i type empid in textbox, empmanager name shod be display in supervisor dropdown.
if i type 1001 empid, corresponding manager name kanna should display in dropdown using entity framework.pls help me


empid empname empmanagerid
1001 jay 1002
1002 kanna 1001
1003 chandru 1002
1004 priya 1003
1005 venkat 1003
1006 ramana 1003
1007 sekhar 1002
1008 j 1007
NULL NULL NULL

Employee ID: TEXTBOX
Employee Name: TEXTBOX

Supervisor": DROPDOWNLIST
Posted
Updated 10-Oct-11 20:31pm
v3

1 solution

you can use LINQ to query the Entity i.e. the table and/or lambda expressions to fetch the data you want. But my question here is, do you want to retrieve the name as you type the id in the text box or after you have typed the ID and tabbed out or clicked a button? The former is pretty much like using "LIKE" in a SQL query and the latter is like doing an exact search based on an ID. Lambda Expressions can make it extremely easy for you to query the Entity much like a SQL query and then bind the results to the drop down.

Explore a little and hack a lot and I am sure you will find your answer.

Cheers...
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900