Welcome to the group. We look forward to providing expert .NET Generics help. -- Thank you, Ryan Olshan Website - http://www.StrongTypes.com <Rolog> -...
The first time I heard about generics I didn't understand what they were until I read the c# 2.0 spec. It's awesome how far templates from C++ have come. I...
Welcome to the group rob. Its good to have a season veteran. ... -- Eric Ramseur .NET Consultant cell: 540-207-6403 "Chance favors the prepared Mind" ...
StrongTypes.com is an excellent resource for learning about Generics. Learnasp.com some ASP.NET 2.0 examples and http://www.asp.net is the offical site for...
Refering to this which I found on Microsoft's site: List<T> is basically a better ArrayList. It is optimized for speed, size, and power. Use it for majority of...
Looks like you are using a collection and not an API. I think its fine. ... -- Eric Ramseur Microsoft.NET Consultant ... http://eramseur.blogspot.com |...
Oh, man--i got all caught up in my answer and lost sight of the original question, sorry 'bout that. The design guidelines touch on the answer. From here: ...
I don't see an advantage to using generics in this scenario; (whether its Collection<T> or List<T>). I see a disadvantage since a generic object is used in...
Here's an interesting article that I came across regarding using nullable types with typed DataSets. Apparently, this feature was cut out at the last minute....
Hi Dave, This most likely has to do with the primary key. Make sure that the primary key is included in the DataKeyNames property for the GridView. HTH Thank...
Thanks Ryan, Ok, that wasn't the problem. I had that specified in the GridView already. The problem was my function UpdateAllergy, this is what it should be: ...
I think Generics will solve my need for strong type casting with web services but I am having a problem with the Web Service Code. Any ideas on how to pass an...
Hi, You can't use Generics with web services. Ryan Thank you, Ryan Olshan Website - http://www.StrongTypes.com <http://www.strongtypes.com/> Group -...
I'm trying to loop through a reader and put all the values into a generic list. public T RStoList<T>(SqlDataReader rdr, int index) { List<T> list = new...
Since GetValue returns an object, you'd have to cast it to T. public T RStoList<T>(SqlDataReader rdr, int index) { List<T> list = new List<T>(); while...
Hello everyone, this is my first post so please bare with me. I am trying to understand why I can't cast generic class to a class of a base type. I have the...
What is the exception or compiler error you are getting? Thank you, Ryan Olshan Website - http://www.StrongTypes.com <http://www.strongtypes.com/> Group -...
Talk about simple eh? How you're going to keep all this stuff straight is beyond me. You've got Contact AND Contract all goo'd together and triple inheritance...
Funny thing is that I did exactly what you're talking about. interface ILetter { } class A : ILetter { private string _ID; public string ID { get { return...
I'm not expert, in anybody's book, but I believe you're trying to use an interface like a base class. An interface is really just a signature, a template if...
Hey Dave thanks for your help and insight into casting to an Interface. I understand what you mean, and I follow your example to the T. My only problem is that...
... to turn a person into a painting. Dave, your anology is wrong. It's perfectly valid to cast an object to an interface it supports. Inclusive you don't even...
Santiago, Searching on Groups.google.com Generic types are typesafe to the type they are bound to. From the draft of the ECMA spec: <quote> No special...