Type Inference in VB.net 9.0
July 28, 2007
I typed Dim x = New List(Of String) but on the next line I realized that the implicit type inference didn’t work and Intellisense treated x as Object. It turns out, it was an easy fix. You have to open the project properties and turn “Option infer” to On. Or type
Option Infer On
at the top of your class.
Posted in

content rss

Add New Comment
Thanks. Your comment is awaiting approval by a moderator.
Do you already have an account? Log in and claim this comment.
Add New Comment
Trackbacks