Archive for May, 2010

Sample LINQ Queries in .net

Posted on May 20 2010 by Sachin Jain

1) Simple Query
var CustQuery= from cust in customers
select cust;
2) Where Clause

var DelhiCustomerQuery = from cust in customers
where cust.City == “Delhi”
select cust;
Logical Operator
where cust.City==”delhi” && cust.Name == “mumbai”
3) Order by
var DelhiCustomerQuery = from cust in customers where cust.City == “Delhi” orderby cust.Name ascending
select cust;
4) Group by
var QueryGroupByCity = from cust in customers group cust by cust.City
Now [...]

3 Key new features in .net 4.0

Posted on May 20 2010 by Sachin Jain

Following are the 3 new Key features in .net 4.0
1) Windows work flow and WCF 4.0:- This is a major change in 4.0.
In WCF they have given following features :-

Dynamic Service and End Point discovery – The problem was faced in earlier version of WCF that if theend point has been changed at service [...]

Difference between dynamic and var keyword .net 4.0

Posted on May 19 2010 by Sachin Jain

In .net 4.0 dynamic keyword has been introduced. This allows you to define the object without specifying its type. So let say we have following string :-

string s = “sachin”;

We can define another variable without specifying the type

dynamic d = s;

Now this can also be done through var keyword so whats the difference?
The difference is [...]

Get Adobe Flash playerPlugin by wpburn.com wordpress themes

Powered by Sachin Jain

Powered by Olark