If the variable is declared with a specific type, these conversions are not necessary. Before VB can use an object variable, it must determine its type and perform the necessary conversions. Integer variables are optimized for storing integers, and date variables are optimized for storing dates. Why bother to specify the type if one type suits all? On the surface, using object variables might seem like a good idea, but they have their disadvantages. Object variables can store any type of data. Numeric variables store numbers, and string variables store text. The two major variable categories are numeric and string. Visual Basic recognizes the following five categories of variables:
0 Comments
Leave a Reply. |