Imran's personal blog

January 2, 2014

ASP.NET/C# Linq/Web Service notes

Filed under: Uncategorized — ipeerbhai @ 10:35 pm

Having recently upgraded my ASP.NET code from .NET 2.0 to .NET 4.5, a few things I don’t expect to do often have entered my mind:

1. C# Linq has an implicit language now.  You can do this:

IEnumerable<Type> lstOfTypes = lstParent.Where( a => a.Property == false );

Ok — this means you take a parent that happens to be a list( Actually, anything that implements IEnumerable ), use a LINQ where clause, and an implicitely typed variable, a, of the correct element type specified in the original parent IEnumerable.  ( They call these implicitely typed variables, “Predicates” ).

2. wsdl is now here:

%ProgramFiles(x86)%\Microsoft SDKs\Windows\v8.0A\bin\NETFX 4.0 Tools\wsdl.exe

Usage is wsdl    /language:C#     /out:ProxyClass.cs    http://URLToASMX

 

Advertisements

1 Comment »

  1. very nice. Thanks.

    Take a look into this article http://www.etechpulse.com/2012/09/all-about-web-service-aspnet.html

    Comment by Ayesha — April 22, 2014 @ 7:16 am | Reply


RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Create a free website or blog at WordPress.com.

%d bloggers like this: