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
Dinesh Santhalingam
NA
737
367.5k
How to load Arraylist
Jan 5 2017 12:46 AM
Here I load array from data table to array list
public static ArrayList LoadView()
{
DataTable
dt
=
new
DataTable();
DataView
view
=
new
DataView(dt);
view.RowFilter
= (("
Name
=
'AD'
"));
DataTable
dtcopy
=
view
.ToTable("Selected", false, "Row1", "Row2");
var
arr
=
dtcopy
.Rows.Cast
<
DataRow
>
().Select(
r
=
>
r.ItemArray).ToArray();
ItemList.Add(arr1);
DataView
view2
=
new
DataView(dt);
view2.RowFilter
= (("
Name
=
'ProE'
"));
DataTable
dtcopy2
=
view2
.ToTable("Selected", false, "Row1", "Row2");
// remove some column from datatable
var
arr2
=
dtcopy2
.Rows.Cast
<
DataRow
>
().Select(
r
=
>
r.ItemArray).ToArray();//Convert datatable to array
//return arr2;
ItemList.Add(arr2);
return Itemlist;
}
Here i have two arrays in my array list.Now i want to append it in a particular array in javascript
Javascript:
PageMethods.LoadView();
function LoadSucc(obj,obj1)//Retur arraylist
{
var
goog
= [];
goog
=
obj
;
var
goog1
= [];
goog1
=
obj1
;
}
Hope you undestand my problem .Suggest me some ideas to solve my issue
Reply
Answers (
1
)
how to generate a hotelbill
why we are using file io in c#