Tech
Forums
Jobs
Books
Events
Interviews
Live
More
Learn
Training
Career
Members
Videos
News
Blogs
Login
Sign Up
Ask Question
2
Reply
How to convert anonymous type to my database type
Asp.Net Hein
Jun 17 2016 4:50 AM
253
Reply
var user = (
db.Users
.Where(u => u.CountryId == c)).Select(
u=> new { u.UserName, u.Email, u.Country.Name, u.PhoneNumber, u.LastLogin
});
In this code, the datatype of 'Select' part is 'anonymous'. I don't want anonymous datatype and I want db.Users type. Kindly let me know how to solve this and thanks a lot for viewing my question.
Upload Source Code
Select only zip and rar file.
Post
Reset
Cancel
Answers (
2
)
Next Recommended Forum
picture in picture object using path in crystal report
Javascript numeric validation