June 2006
Intermediate to advanced
1344 pages
42h 52m
English
An important feature of argument passing is implicit argument conversion—converting an argument’s value to a type that the method expects to receive in its corresponding parameter. Visual Basic supports both widening and narrowing conversions. A widening conversion occurs when an argument is converted to a parameter of another type that can hold more data, whereas a narrowing conversion occurs when there is potential for data loss during the conversion (i.e., a conversion to a parameter of a type that holds a smaller amount of data). Figure 7.6 lists the widening conversions supported by Visual Basic that occur between primitive types. In addition to the conversions in Fig. 7.6, all primitive type variables ...
Read now
Unlock full access