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
SIVA
NA
742
707.6k
How to do this with Datatable
Apr 4 2012 1:42 PM
Dear all,
I have 2 dropdown list for hours(0-23) & minutes(0-59).
Now i ll take datatable with & i ll add 2 columns for that as follows.
Datatable oDT=new Datatable();
oDT.columns.Add("H",typeof(int));
oDT.columns.Add("M",typeof(int));
now by using for loops i need to add values to H column & M column & i ll need to bind those values to Dropdown list.
bt When I am trying to add values to datatable i m getting error.
for (int i=0;i<59;i++)
oDT["M"]=i;
Error: Can't applying indexing with [] to an expression of type system.data.datatable.
Can anybody resolve this error & let me know how to do this.
Reply
Answers (
5
)
Insert a Excel File into VS (Asp.net 4.0)
HTML & Server Controls In ASP.NET