February 2011 - Posts


Comments

Getting the default value for a Type by marianor

Sometimes we need to get a default value for an specific type but we only know the type in runtime, then we can not use default(T). One way to do this is to use a simple extension method: public   static   object DefaultValue( this   Type...
Filed under: ,
More Posts