Solved

Entity Framework - LINQ to Entities query to populate DropDownList control

Posted on 2008-10-08
1
1,839 Views
Last Modified: 2013-11-11
Experienced .NET web developer here looking to get going on all this Entity Framework stuff. I have a book ordered, but it doesn't ship till December! I have the entity data model created from my database and made a few modifications to that and I think I have a fair grasp on all that. I've also managed a couple of LINQ queries to return string lists of values from a single property queried across a range of objects (such as 'from c in entityModel.Contacts select c.Name;'). What I'd like to see is a simple example of is how to write a method like getContactList() to query my Entity Data model and return a ContactID and Name in some form that can be bound to a DropDownList control.

Thanks
0
Comment
Question by:danburyit
1 Comment
 
LVL 1

Accepted Solution

by:
danburyit earned 0 total points
ID: 22677462
This seems to be very helpful.

http://www.primaryobjects.com/CMS/Article95.aspx
0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
HTTPS jquery doesn't work 9 63
jquery datatables, asp.net MVC 9 42
SQL Help 27 45
VB.NET 2008 - Windows Protected Your PC 7 16
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…

803 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question