|
|
SyntaxUsing resourceExpression... [statements] End Using
DescriptionNew in 2005. The Using...End Using block construct is used to execute a series of statements on one or more resource objects, and to have those objects automatically release all of their allocated resources when the block is left in any way. The Using statement is basically a formal method of ensuring that the object's Dispose method is called when the object is no longer needed. Usage at a Glance
Version DifferencesThe Using...End Using statement is new with Visual Basic 2005. See AlsoWith...End With Statement |
|
|