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
imran azam
NA
98
12.8k
Select record between two column from DataTable.
Apr 21 2016 1:11 AM
Hi Members,
I have searched on Google but didn't find any solution pls anyone help me out.
Problem: I have three Column ID,Value1,Value2 in the Datatable.
DataTable is looking like this :
ID Value1 Value2
1 10 20
2 15 30
I want to find the data between range means let's say in example :
if i enter 15 to 30 it should not allow because 15 is already present between 10 to 20.
This is the code i have written if i enter same value again then i will get message:
if (dtCurrentTable.AsEnumerable().Any(row =>Convert.ToInt32(drCurrentRow["Value1"]) == row.Field<Int32>("Value1") &&Convert.ToInt32(drCurrentRow["Value2"]) == row.Field<Int32>("Value2")))
{
//msg
}
So, How to write Code to achieve my task as i explain above.
Reply
Answers (
3
)
Bootstrap tab
How to open IIS v5.1 Url rewrite option?