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
Deepak Saini
NA
667
50.2k
how to Implicitly intilization of the var datatype in Switch
Dec 19 2015 6:59 AM
Hello,
i wont to in Implicitly intilization of the var datatype in Switch case.but i may nor print this.any body help me asap....
var k;
switch (Srt_TxtBoxValue)
{
case "Managed":
k = clientMachines.Where(x =>x.Is_Scheduled==false && x.Is_Installed==true);
break;
case "Unmanaged":
k = clientMachines.Where(x =>x.Is_Scheduled==false && x.Is_Installed==false);
break;
case "Scheduled for Uninstallation":
k = clientMachines.Where(x =>x.Is_Scheduled==true && x.Is_Installed==true);
break;
case "Scheduled for Installation":
k = clientMachines.Where(x =>x.Is_Scheduled==true && x.Is_Installed==false);
break;
default:
k = clientMachines.Where(x =>x.Host_Name.Contains(Srt_TxtBoxValue) || x.IP_Address.Contains(Srt_TxtBoxValue) || x.MAC_Address.Contains(Srt_TxtBoxValue) || x.Domain_Name.Contains(Srt_TxtBoxValue));
break;
}
Reply
Answers (
2
)
Object cannot be cast from DBNull to other types.
How to create custom events?