Click here to Skip to main content
15,903,362 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello Friends,

Can anyone tell me, which is faster:

1. Getting a dataset from Object Layer and binding to a grid.
2. Converting a dataset to a collection and binding to a grid.

Can anyone provide a link to such an example (Converting dataset to collection and how to bind it to grid)?

Thanks in advance
Posted
Updated 17-Jun-11 1:19am
v2
Comments
Slacker007 17-Jun-11 7:20am    
Edited for grammar and readability.
dhage.prashant01 17-Jun-11 8:09am    
Refer this link for something extra
http://msdn.microsoft.com/hi-in/magazine/cc163751(en-us).aspx

You can bind dataset having table to grid like

GridView1.DataSource=<dataset_obj>.Tables[Index];
GridView1.DataBind();</dataset_obj>
 
Share this answer
 
v2
first one will work faster.
Thanks.
 
Share this answer
 
Comments
dhage.prashant01 17-Jun-11 7:54am    
But I have gone through many site, people use collection rather than dataset. Any specify reason?
Tarun.K.S 17-Jun-11 8:04am    
Please give reasons. You could have added it as a comment instead.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900