Linq
-
Who of you VB.NET programmer is using linq and if you are could you share some things that you are using it for in the "real world".
Humble Programmer
-
Who of you VB.NET programmer is using linq and if you are could you share some things that you are using it for in the "real world".
Humble Programmer
I use a lot of generic collections to hold my object instances. For this reason I have found a lot of the extension methods in combination with lambda expressions to really tighten up my code. I have a large list of examples on a post at: http://www.anothercodesite.com/Blog/post/2008/09/07/Lambda-Expressions-Theres-More-than-One-Way-to-Skin-a-Generic-List.aspx[^] The samples are all in C# towards top of post, and VB towards bottom.
Troy Johnson www.anothercodesite.com/blog
-
I use a lot of generic collections to hold my object instances. For this reason I have found a lot of the extension methods in combination with lambda expressions to really tighten up my code. I have a large list of examples on a post at: http://www.anothercodesite.com/Blog/post/2008/09/07/Lambda-Expressions-Theres-More-than-One-Way-to-Skin-a-Generic-List.aspx[^] The samples are all in C# towards top of post, and VB towards bottom.
Troy Johnson www.anothercodesite.com/blog
Thanks for the reply, I know this may sound dumb but I am still unsure of how this can help me. We write software that uses a mySQL backend with stored procedures and some dynamically generated SQL. Can you give me a instance when it would be beneficial to use linq. The application just retrieves and displays info and lets the users update that info. One things that I thought sounded close to the explanation I have had of the use of linq, is to read a dataset in memory currently we are reading the xml file each time we need a setting for the app(I know that is very slow) this is a piece of code I did not write but have been wanting to find a better solution to for a while now. Another thought is it more efficient to read a large list of data in from the database and then search through with linq of write a huge ugly SQL statement to only get the rows I am needing.
Humble Programmer