<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Just playing with Generics in Visual Basic Whidbey</title><link>http://blogs.msdn.com/duncanma/archive/2004/02/19/76587.aspx</link><description>My simple class: Public Class Customer Dim m_CustomerName As String Dim m_CustomerID As Integer Public Property CustomerName() As String Get Return m_CustomerName End Get Set ( ByVal Value As String ) m_CustomerName = Value End Set End Property Public</description><dc:language>en-US</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>re: Just playing with Generics in Visual Basic Whidbey</title><link>http://blogs.msdn.com/duncanma/archive/2004/02/19/76587.aspx#76612</link><pubDate>Fri, 20 Feb 2004 00:11:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:76612</guid><dc:creator>Julie Lerman</dc:creator><description>ooh - I have to add this part to my presentation:&lt;br&gt; For Each cust As Customer In myCustomers&lt;br&gt;            Debug.Print(cust.CustomerName)&lt;br&gt; Next&lt;br&gt;&lt;br&gt;God I have wanted to do that for years! &amp;lt;g&amp;gt;&lt;br&gt;</description></item><item><title>re: Just playing with Generics in Visual Basic Whidbey</title><link>http://blogs.msdn.com/duncanma/archive/2004/02/19/76587.aspx#76621</link><pubDate>Fri, 20 Feb 2004 00:25:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:76621</guid><dc:creator>Darren Neimke</dc:creator><description>Aside from the new syntax but, that example doesn't really show me anything about super special Generics per se.  For example, where you have:&lt;br&gt;&lt;br&gt;    Dim myCustomers _&lt;br&gt;            As New Generic.List(Of Customer)&lt;br&gt;&lt;br&gt;Change it to:&lt;br&gt;&lt;br&gt;    Dim myCustomers _&lt;br&gt;            As New ArrayList&lt;br&gt;&lt;br&gt;Compile it in 2003 and run it.  Voila!</description></item><item><title>re: Just playing with Generics in Visual Basic Whidbey</title><link>http://blogs.msdn.com/duncanma/archive/2004/02/19/76587.aspx#76638</link><pubDate>Fri, 20 Feb 2004 00:57:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:76638</guid><dc:creator>Cory Smith</dc:creator><description>Darren, your missing the point of Generics.  It's giving you strongly typed collections without having to write a ton of code.  For example, create a new class and tell it to Inherit CollectionBase.  Put your cursor on CollectionBase and go to the help for it.  From there, to the overview for CollectionBase and scroll down to the sample it shows.  Now, you have something to compare what Duncan is pointing out and what you have to do today to accomplish the same sort of thing.</description></item><item><title>re: Just playing with Generics in Visual Basic Whidbey</title><link>http://blogs.msdn.com/duncanma/archive/2004/02/19/76587.aspx#76641</link><pubDate>Fri, 20 Feb 2004 01:04:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:76641</guid><dc:creator>Darren Neimke</dc:creator><description>Cory, yes I'm aware of how cool Generics are and when you will use them.  My point is that the only thing that reading Duncan's demo will give you is a glimpse of the new syntax.&lt;br&gt;&lt;br&gt;So, I guess if Duncan is saying:&lt;br&gt;&lt;br&gt;    &amp;quot;Now, isn't that nice?&amp;quot; (that migrating code will be simple)&lt;br&gt;&lt;br&gt;Then, I agree and I probably missed his point.&lt;br&gt;&lt;br&gt;But, if he is saying:&lt;br&gt;&lt;br&gt;    &amp;quot;Now, isn't that nice?&amp;quot; (that this *new* stuff rocks based on what I've shown you in this sample)&lt;br&gt;&lt;br&gt;Then, no... I don't think that this demo shows much.&lt;br&gt;&lt;br&gt;I really only &amp;quot;piped-up&amp;quot; about it because I thought that I might have missed something important that was shown here.</description></item><item><title>re: Just playing with Generics in Visual Basic Whidbey</title><link>http://blogs.msdn.com/duncanma/archive/2004/02/19/76587.aspx#76674</link><pubDate>Fri, 20 Feb 2004 02:14:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:76674</guid><dc:creator>Ben Dover</dc:creator><description>Woo yay *walks off*</description></item><item><title>re: Just playing with Generics in Visual Basic Whidbey</title><link>http://blogs.msdn.com/duncanma/archive/2004/02/19/76587.aspx#76735</link><pubDate>Fri, 20 Feb 2004 04:14:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:76735</guid><dc:creator>Andres Morales</dc:creator><description>Hi, i change only two lines, but i don&amp;#180;t understand this line &lt;br&gt;&lt;br&gt;C.CustomerID = i&lt;br&gt;&lt;br&gt;is necesary?&lt;br&gt;&lt;br&gt;Thanks&lt;br&gt;&lt;br&gt;</description></item><item><title>Visual Basic Generics</title><link>http://blogs.msdn.com/duncanma/archive/2004/02/19/76587.aspx#76769</link><pubDate>Fri, 20 Feb 2004 08:35:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:76769</guid><dc:creator>BufferOverrun</dc:creator><description /></item><item><title>To Andres</title><link>http://blogs.msdn.com/duncanma/archive/2004/02/19/76587.aspx#76807</link><pubDate>Fri, 20 Feb 2004 06:20:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:76807</guid><dc:creator>Duncan Mackenzie</dc:creator><description>It isn't necessary at all, I was just trying to actually do something with each item as I created them.... merely filler code.</description></item><item><title>RE: Just playing with Generics in Visual Basic Whidbey</title><link>http://blogs.msdn.com/duncanma/archive/2004/02/19/76587.aspx#77026</link><pubDate>Fri, 20 Feb 2004 14:16:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:77026</guid><dc:creator>Luciano Evaristo Guerche</dc:creator><description>I have seen C# generic samples and can quite understand it. In the VB sample presented what I think was missing was to mention the Generic.List declaration I guess might be:&lt;br&gt;&lt;br&gt;namespace Generic&lt;br&gt;{&lt;br&gt; class List&amp;lt;T&amp;gt;&lt;br&gt; {&lt;br&gt;   List(&amp;lt;T&amp;gt;) //constructor&lt;br&gt;   {...}&lt;br&gt;  }&lt;br&gt;}&lt;br&gt;&lt;br&gt;And whose call in C# would be&lt;br&gt;&lt;br&gt;List&amp;lt;Custumer&amp;gt; myCustomers = new List&amp;lt;Customer&amp;gt;&lt;br&gt;&lt;br&gt;For me, what was to grab is that List&amp;lt;Custumer&amp;gt; myCustomers = new List&amp;lt;Customer&amp;gt; in C#, translates to Dim myCustomer As New Generic.List(Of Customer).&lt;br&gt;&lt;br&gt;Am I right? Any comment welcome.&lt;br&gt;&lt;br&gt;--&lt;br&gt;Luciano Evaristo Guerche&lt;br&gt;Jacarei, SP, Brazil&lt;br&gt;P.S.: I cannot believe that, I am able to write little C# snippets!</description></item><item><title>RE: Just playing with Generics in Visual Basic Whidbey</title><link>http://blogs.msdn.com/duncanma/archive/2004/02/19/76587.aspx#77050</link><pubDate>Fri, 20 Feb 2004 14:33:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:77050</guid><dc:creator>Luciano Evaristo Guerche</dc:creator><description>Duncan,&lt;br&gt;&lt;br&gt;Is it possible to also create generic classes on VB.NET or just consume them? If your answer is that it is possible to create them, I wonder you would mind porting the article &amp;quot;An Introduction to C# Generics&amp;quot; found at &lt;a target="_new" href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dv_vstechart/html/csharp_generics.asp"&gt;http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dv_vstechart/html/csharp_generics.asp&lt;/a&gt; to VB.NET.&lt;br&gt;&lt;br&gt;I read it and feel it is a good example.&lt;br&gt;&lt;br&gt;Regards,&lt;br&gt;&lt;br&gt;Luciano Evaristo Guerche&lt;br&gt;Jacarei, SP, Brazil</description></item><item><title>re: Just playing with Generics in Visual Basic Whidbey</title><link>http://blogs.msdn.com/duncanma/archive/2004/02/19/76587.aspx#77196</link><pubDate>Fri, 20 Feb 2004 18:50:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:77196</guid><dc:creator>Jorriss Orroz</dc:creator><description>This is just cool.  I already spend too much time creating typed custom collections.  Generics should add another cool tool to add to the 'ol toolbox.&lt;br&gt;&lt;br&gt;Thanks for the snipit Duncan.</description></item><item><title>VB Sample: Generics</title><link>http://blogs.msdn.com/duncanma/archive/2004/02/19/76587.aspx#77199</link><pubDate>Fri, 20 Feb 2004 21:53:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:77199</guid><dc:creator>Random Thoughts of Jorriss</dc:creator><description /></item><item><title>re: Just playing with Generics in Visual Basic Whidbey</title><link>http://blogs.msdn.com/duncanma/archive/2004/02/19/76587.aspx#77922</link><pubDate>Sun, 22 Feb 2004 14:26:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:77922</guid><dc:creator>Hans Jergen Ohff </dc:creator><description>Yet another boring comment on Generics because nobody can think of anything original to talk about.</description></item><item><title>re: Just playing with Generics in Visual Basic Whidbey</title><link>http://blogs.msdn.com/duncanma/archive/2004/02/19/76587.aspx#77923</link><pubDate>Sun, 22 Feb 2004 14:26:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:77923</guid><dc:creator>Hans Jergen Ohff </dc:creator><description>Yet another boring comment on Generics because nobody can think of anything original to talk about.</description></item><item><title>Workaround: Arrays with non-zero lower bounds</title><link>http://blogs.msdn.com/duncanma/archive/2004/02/19/76587.aspx#116669</link><pubDate>Tue, 20 Apr 2004 14:39:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:116669</guid><dc:creator>Visual Basic Frequently Asked Questions</dc:creator><description /></item><item><title>re: Just playing with Generics in Visual Basic Whidbey</title><link>http://blogs.msdn.com/duncanma/archive/2004/02/19/76587.aspx#148741</link><pubDate>Fri, 04 Jun 2004 19:32:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:148741</guid><dc:creator>Matt</dc:creator><description>The cool part that Darren wasn't seeing would be changing the for each loop as follows:&lt;br&gt;&lt;br&gt;For i As Integer = 0 To myCustomer.Count - 1&lt;br&gt;    ' Notice the strong typing of the Item property&lt;br&gt;    Debug.Print(myCustomers.Item(0).CustomerName)&lt;br&gt;Next</description></item></channel></rss>