Programming Element Support Changes Summary
Support for various programming elements has changed since Visual Basic 6.0, mostly for interoperability with the common language runtime. Many Visual Basic 6.0 elements are renamed, reclassified, or combined with other programming elements. Several elements are no longer supported, because the common language runtime (CLR) includes functionality that makes them unnecessary. For more information, see Common Language Runtime.
For additional information about changes to Visual Basic, see Help for Visual Basic 6.0 Users. This topic includes information about changes to the integrated development environment (IDE), Web functionality, projects, forms, constants, and the Circle, Line, and Pset methods.
Changed Elements
The following table lists changed programming elements and their replacements.
Visual Basic 6.0 programming element |
Visual Basic 2008 equivalent |
Namespace, class, or run-time library location |
---|---|---|
Abs function |
||
AscB function |
Visual Basic Run-Time Library Members, Strings module |
|
As Any keyword phrase |
Not supported in Visual Basic 2008. See Declaration Syntax for Visual Basic 6.0 Users. |
Does not apply |
Atn function |
||
Calendar property |
||
ChDir statement |
Visual Basic Run-Time Library Members, FileSystem module |
|
ChDrive statement |
Visual Basic Run-Time Library Members, FileSystem module |
|
Chr$,ChrB, functions |
Visual Basic Run-Time Library Members, Strings module |
|
Close statement |
Visual Basic Run-Time Library Members, FileSystem module |
|
Cos function |
||
Currency data type |
Decimal Data Type; see Data Type Changes for Visual Basic 6.0 Users |
Visual Basic Run-Time Library Members, VariantType Enumeration |
CVDate function |
Visual Basic Run-Time Library Members, DateAndTime module |
|
CVErr function |
Does not apply |
|
Date function, Date statement |
Visual Basic Run-Time Library Members, DateAndTime module |
|
Date$ function |
Visual Basic Run-Time Library Members, DateAndTime module |
|
Debug.Assert method |
||
Debug.Print method |
Write, WriteIf, WriteLine, and WriteLineIf methods |
|
Deftype statements |
Not supported in Visual Basic 2008. See Data Type Changes for Visual Basic 6.0 Users |
Does not apply |
DeleteSetting statement |
Visual Basic Run-Time Library Members, Interaction module |
|
DoEvents function |
||
Empty keyword |
Does not apply |
|
Eqv operator |
Does not apply |
|
Exp function |
||
FileCopy statement |
Visual Basic Run-Time Library Members, FileSystem module |
|
Get statement |
Visual Basic Run-Time Library Members, FileSystem module |
|
GoSub statement |
Not supported in Visual Basic 2008; use the Return Statement. See Control Statement for Visual Basic 6.0 Users. |
Does not apply |
Imp operator |
Not supported in Visual Basic 2008. See Not and Or operators, and Boolean Operator for Visual Basic 6.0 Users. |
Does not apply |
Initialize event |
Not supported in Visual Basic 2008; use Sub New. See Class_Initialize Changes for Visual Basic 6.0 Users and Using Constructors and Destructors |
Does not apply |
Input #, Input$ statements, Input$, InputB, InputB$ functions |
Visual Basic Run-Time Library Members, FileSystem module |
|
Instancing property |
Not supported in Visual Basic 2008. For class-level declarations, see Private (Visual Basic) and Public (Visual Basic). For procedure-level declarations, see Shared (Visual Basic). |
Does not apply |
InStrB function |
Visual Basic Run-Time Library Members, Strings module |
|
IsEmpty function |
Visual Basic Run-Time Library Members, Information module |
|
IsMissing function |
Not supported in Visual Basic 2008. See Procedure Declaration for Visual Basic 6.0 Users. |
Does not apply |
IsNull function |
Visual Basic Run-Time Library Members, Information module |
|
IsObject function |
Visual Basic Run-Time Library Members, Information module |
|
Kill statement |
Visual Basic Run-Time Library Members, FileSystem module |
|
LCase$ function |
Visual Basic Run-Time Library Members, Strings module |
|
Left$, LeftB, LeftB$ functions |
Visual Basic Run-Time Library Members, Strings module |
|
LenB function |
Visual Basic Run-Time Library Members, Strings module |
|
Let, Set assignment statements |
Not supported in Visual Basic 2008; the new Set statement is unrelated to the older one. See Default Property Changes for Visual Basic 6.0 Users. |
Does not apply |
Line Input # statement |
Visual Basic Run-Time Library Members, FileSystem module |
|
Load statement |
New (Visual Basic) keyword, Show method, Load event |
Visual Basic Run-Time Library Members, System.Windows.Forms namespace |
Lock statement |
Visual Basic Run-Time Library Members, FileSystem module |
|
Log function |
||
LSet, RSet statements |
LSet Function, PadRight, PadLeft; see Data Type Changes for Visual Basic 6.0 Users |
Visual Basic Run-Time Library Members, Strings module; and System Namespace, String Class |
LTrim$ function |
Visual Basic Run-Time Library Members, Strings module |
|
MidB function |
Visual Basic Run-Time Library Members, Strings module |
|
MidB statement |
Visual Basic Run-Time Library Members, Strings module |
|
MkDir statement |
Visual Basic Run-Time Library Members, FileSystem module |
|
Name statement |
Visual Basic Run-Time Library Members, FileSystem module |
|
Now function |
Visual Basic Run-Time Library Members, DateAndTime module |
|
Null keyword |
Does not apply |
|
Oct$ function |
Visual Basic Run-Time Library Members, Conversion module |
|
On ... GoSub construction |
Not supported in Visual Basic 2008; use Select...Case Statement. See Control Statement for Visual Basic 6.0 Users. |
Does not apply |
On ... GoTo construction |
Not supported in Visual Basic 2008; use Select...Case Statement. See Control Statement for Visual Basic 6.0 Users. |
Does not apply |
Open statement |
Visual Basic Run-Time Library Members, FileSystem module |
|
Option Base statement |
Not supported in Visual Basic 2008. See Array Bounds for Visual Basic 6.0 Users. |
Does not apply |
Option PrivateModule statement |
Not supported in Visual Basic 2008; use Module Statement. |
Does not apply |
Print # statement |
Visual Basic Run-Time Library Members, FileSystem module |
|
Property Get, Property Let, Property Set statements |
Not supported in Visual Basic 2008. See Property Procedure Changes for Visual Basic 6.0 Users. |
Does not apply |
Put statement |
Visual Basic Run-Time Library Members, FileSystem module |
|
Reset statement |
Visual Basic Run-Time Library Members, FileSystem module |
|
Right$, RightB functions |
Visual Basic Run-Time Library Members, Strings module |
|
RmDir statement |
Visual Basic Run-Time Library Members, FileSystem module |
|
Round function |
||
RSet, LSet statements |
RSet Function; see Data Type Changes for Visual Basic 6.0 Users |
Visual Basic Run-Time Library Members, Strings module |
RTrim$ function |
Visual Basic Run-Time Library Members, Strings module |
|
SaveSetting statement |
Visual Basic Run-Time Library Members, Interaction module |
|
Scale method |
Not supported in Visual Basic 2008. |
Does not apply |
Set, Let assignment statements |
Not supported in Visual Basic 2008; the new Set statement is unrelated to the older one. See Default Property Changes for Visual Basic 6.0 Users |
Does not apply |
SetAttr statement |
Visual Basic Run-Time Library Members, FileSystem module |
|
Sgn function |
||
Sin function |
||
Sqr function |
||
String function |
String Constructor; see String ($) Function for Visual Basic 6.0 Users |
|
String ($) functions |
Not supported in Visual Basic 2008. See String ($) Function for Visual Basic 6.0 Users. |
Does not apply |
Terminate event |
Not supported in Visual Basic 2008; use Sub Dispose and Sub Finalize. See Using Constructors and Destructors. |
Does not apply |
Time function, Time statement |
Visual Basic Run-Time Library Members, DateAndTime module |
|
Time$ function |
Visual Basic Run-Time Library Members, DateAndTime module |
|
Timer function |
Visual Basic Run-Time Library Members, DateAndTime module |
|
Trim$ function |
Visual Basic Run-Time Library Members, Strings module |
|
Type statement |
Not supported in Visual Basic 2008; use Structure Statement. See Structure Declaration for Visual Basic 6.0 Users. |
Does not apply |
UCase$ function |
Visual Basic Run-Time Library Members, Strings module |
|
Unlock statement |
Visual Basic Run-Time Library Members, FileSystem module |
|
Variant data type |
Object Data Type; see Universal Data Type Changes for Visual Basic 6.0 Users |
Does not apply |
Wend keyword |
While...End While Statements and End Statement; see Control Statement for Visual Basic 6.0 Users |
Does not apply |
Width # statement |
Visual Basic Run-Time Library Members, FileSystem module |
|
Write # statement |
Visual Basic Run-Time Library Members, FileSystem module |
See Also
Other Resources
Language Changes for Visual Basic 6.0 Users