TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Abhilash J A
535
2.4k
596.3k
list object if contain one value then return another one c#
Dec 23 2016 5:29 AM
Hello,
I have list items
The
Priority
list's object may contain 1 or 2 or 3.
If
Priority
contain 1 then return "Low"
If
Priority
contain 2 then return "Medium"
If
Priority
contain 3 then return "High"
I have tried...
public
class
DocumentsUser
{
public
string
Priority {
get
;
set
; }
}
List<DocumentsUser> objUserSetUp = objUserSetUp1.Select(m =>
new
DocumentsUser()
{
Priority = m.Priority == 3 ?
"High"
:
"Low"
,
//Here I want to manage that contition.
}
How can I do that?
Reply
Answers (
5
)
data table to dictionary
Help Beginner please