Welcome to StrongCoders.com Community Sign in | Join | Help

Blog ( Of Ryan Olshan)

Recent Posts

News

  • About Ryan Olshan

    Join StrongTypes - Free Generics Help By Email
    Join StrongTypes

    Community Credit Winner

    View my MVP profile

    The posts on this weblog are provided "as is" with no warranties and confer no rights. The opinions expressed herin are my own personal opinions and do not represent my employer's view in any way.

    Subscribe to Rolog via My AOL
    Subscribe to Rolog via Bloglines


    Subscribe to Rolog via Feedburner

    Furl Rolog



    Add Rolog to Technorati Favorites


.NET Websites

  • => StrongTypes.com <=
  • Community Credit
  • DotNetCharity.com
  • DotNetSlackers
  • EasyListBox
  • SystemNetMail.com
  • SystemWebMail.com

Blogroll

  • Alex Campbell
  • Carlos Magalhaes
  • Chris Taylor
  • Darren Neimke
  • David Betz
  • Eric Smith
  • Rob Caron
  • Sam Gentile
  • Scott Guthrie
  • Scott Mitchell
  • Tess
  • Wesner Moise

Other Websites

  • 911 Pigeon Alert
  • Pacific Wildlife Project

Thycotic

  • Bryant Smith
  • John Morales
  • Jonathan Cogley

Yahoo! Groups

  • => StrongTypes <=
  • AspNet2
  • AspNet20GridView
  • PayPalDevDotNet
  • RubyOnRails
  • VSTS

Browse by Tags

All Tags » Generics  
  • .NET Misc.
  • Announcements
  • C#
  • Data Access
  • GridView
  • What's wrong with this code?
Free .NET Generics Help from the Experts
Group ( Of Experts) Generics is one of the most noted changes to the .NET Framework 2.0. Generics will reduce overhead due to boxing/unboxing and the amount of errors in your code . Want to learn about .NET Generics but don't know where to start? Join Read More...
XML Generics
Today I answered a thread regarding using generics with XML and it reminded me of the following blog entry regarding XML generics in .NET 3.0: XML Generics Read More...
Inheritence with Generics
I answered a post on the ASP.NET forums where somebody was having problems with Generics and class inheritence. I ended up cooking this up as an example based upon what they had already provided in the thread. using System; using System.Collections.Generic; Read More...
Nullable type to string function
I just answered a thread where somebody wanted to know how to take any nullable type, check if it's value is null, and depending on that either return String.Empty or ToString. Here's how you do that: public static string ConvertNullableToString(T? Read More...
Nullable types and typed DataSets
Earlier today I answered a question on a group where some guy was trying to use nullable types with a typed DataSet. Unfortunately, this feature was cut out at the last moment. But, there is a way around this. Adding Functionality to a Typed DataSet using Read More...
Generic List Collection / ObjectDataSource / GridView Sample
I put together sample code that will run on the Northwind database that demonstrates using a generic List collection as a data source for an ObjectDataSource which populates a GridView control. All you have to do is specify the connection string in Web.config Read More...
A somewhat type-safe String.Format
Using String.Format you can format any string. However, the last parameter that String.Format accepts is of type object. So, to add some type-safety to the mix, the following function works perfectly. VB.NET Public Function FormatString( Of T)( ByVal Read More...
Creating a List of a custom class
Let's say for instance, you want to create a List of your own class, say Employee, where Employee represents an employee. First, we'll start by creating an employee class. [ Serializable ] public class Employee { private bool m_IsSalaried; private int Read More...
Interesting Generic Blog Entries
I was surfing the Internet today and came across David Wheeler's blog, which has some interesting entries on Generics. Anonymous methods and handling events in .NET 2.0 Generics: An introduction Generics: More advanced concepts New and improved event Read More...
What does the ` character stand for?
Take the following code, for example: VB.NET Public Class TestClass( Of T) End Class Response.Write(GetType(TestClass( Of Integer ))) C# public class TestClass { } Response.Write( typeof ( TestClass < int >)); The above code results in Read More...
What's wrong with this generic class?
Q: What's wrong with the below generic class? VB.NET Imports System.Data Imports System.Web Public Class GenericClass( Of T As DataTable) Public Function GetValue( ByVal val As T) As T Return val End Function Public Function GetValue( ByVal val As T) Read More...
Generic Sub Classes
In generics, you can use sub classes just as you would any non-generic sub class. Take the following class and sub class for example: VB.NET Public Class OuterClass( Of T, U, V) Public Class InnerClass( Of T, U) Public Function InnerMethod( ByVal val1 Read More...
Nullable Types
One of the weirder features in C# 2.0 is nullable types. My thinking is as follows: Why complicate things with Nullable, or its shorter version of DataType? (i.e. int?), instead of allowing null values to be assigned to those data types that Read More...
Generic Type Inference
One of the cooler features I like in Generics is type inference. Type inference allows you to call a generic method just as you would a non-generic method using its method signatures as references to the type(s), instead of specifying the type(s). VB.NET Read More...
What's wrong with this generic type?
I love mysteries. However, this one is pretty simple. Q: What is wrong with the following generic type? VB.NET Public Class BaseClass( Of K, V) End Class Public Class SubClass1 Inherits BaseClass( Of K, V) End Class Public Class SubClass2 Inherits BaseClass( Read More...
More Posts Next page »