I'm new to VB.NET programming. What I'm confused about is the different ways one can declare a variable. Would someone please explain the difference between the two declarations below?
Dim sqlcommand As MySqlDataAdapter = New MySqlDataAdapter(sql, db)
And:
Dim anotherSqlcommand As New MySqlDataAdapter(sql, db)
Best Answer
There is no difference.
Sometimes you want to use the first method though if you want to take advantage of interfaces...
Instead of being restricted to List(Of Something)