View Single Post
Old 06-18-2007, 11:47 AM
loquin's Avatar
loquin loquin is offline
Google Hound

Retired Moderator
* Guru *
Join Date: Nov 2001
Location: Arizona, USA
Posts: 12,400

Visual Basic .NETCodemaster's Library
Matt Tagliaferri
ISBN 078214103X

This book is aimed at the experienced VB programmer moving to VB.Net. In it, the author provides nearly 100 "Concise Code Solutions for VB.Net Developers." And, on the whole, he does just that. This is NOT a 'cookbook.' though. Tagliaferri describes the issue, the solution, and the reasoning behind the approach that he takes, usually in a well reasoned discussion. And, he is quite vocal as to the superiority of .Net over Classic VB.

Keep in mind, however, that while the solutions that are provided are workable, and the reasoning is usually sound, occasionally (repeat, occasionally) the underlying discussion as to why .Net is superior to classic VB jist isn't justified. It's NOT the major items. In many ways, VB.Net IS a superior product. It's some of the small items - things that the author, who claims to be a long-time VB user, just gets flat wrong, or overlooks.

For instance, early in the book, Tagliaferri states "Visual Basic has never had operators for performing bitwise functions - until now, that is." (my italics) and then goes on to list VB.Net's 'new' bitwise And, Or, and Xor operators. Cough... Sorry Matt. This is an absolutely incorrect statement. At LEAST since VB4, we've had bitwise And, Or, Xor, and Not available to us. And, they worked just fine, thank you.

In another spot, early in the book, Matt goes on the warpath against redundant function calls, and with good reason. The example he provided is truly a atrocious snippet of code, lifted from a VB programming article, that had three duplicate Instr calls inside a string replace loop, which most folks would agree is very inefficient. Especially with .Net, and its immutable string class. However, while he extols VB.Net, and its 'new' stringbuilder .Replace method, he completely overlooks the fact that VB6 has the Replace function, which efficiently replaces substrings within a string. So, YES, do not use multiple calls to the same function within a loop if at all possible. But, the .Replace solution is not the reason that .Net is superior to VB6.

Overall, it just appears a bit odd that an experienced VB coder would misrepresent such basic VB6 (and sometimes earlier) features.

So, keep in mind that while the solutions that Matt provides appear to be valid, the underlying discussion(s) just might not be...
"I have my standards. They may be low, but I have them!" ~ Bette Middler
"It's a book about a Spanish guy called Manual. You should read it." ~ Dilbert
"To understand recursion, you must first understand recursion." ~ unknown

Last edited by loquin; 06-20-2007 at 12:46 PM.
Reply With Quote