Compartir a través de


SyntaxFactory.TryBlock Método

Definición

Sobrecargas

TryBlock(TryStatementSyntax, SyntaxList<StatementSyntax>, SyntaxList<CatchBlockSyntax>, FinallyBlockSyntax, EndBlockStatementSyntax)

Representa un elemento "Try ... Atrapar... Finalmente... Finalizar bloque Try".

TryBlock()

Representa un elemento "Try ... Atrapar... Finalmente... Finalizar bloque Try".

TryBlock(SyntaxList<StatementSyntax>, SyntaxList<CatchBlockSyntax>, FinallyBlockSyntax)

Representa un elemento "Try ... Atrapar... Finalmente... Finalizar bloque Try".

TryBlock(TryStatementSyntax, SyntaxList<StatementSyntax>, SyntaxList<CatchBlockSyntax>, FinallyBlockSyntax, EndBlockStatementSyntax)

Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb

Representa un elemento "Try ... Atrapar... Finalmente... Finalizar bloque Try".

public:
 static Microsoft::CodeAnalysis::VisualBasic::Syntax::TryBlockSyntax ^ TryBlock(Microsoft::CodeAnalysis::VisualBasic::Syntax::TryStatementSyntax ^ tryStatement, Microsoft::CodeAnalysis::SyntaxList<Microsoft::CodeAnalysis::VisualBasic::Syntax::StatementSyntax ^> statements, Microsoft::CodeAnalysis::SyntaxList<Microsoft::CodeAnalysis::VisualBasic::Syntax::CatchBlockSyntax ^> catchBlocks, Microsoft::CodeAnalysis::VisualBasic::Syntax::FinallyBlockSyntax ^ finallyBlock, Microsoft::CodeAnalysis::VisualBasic::Syntax::EndBlockStatementSyntax ^ endTryStatement);
public static Microsoft.CodeAnalysis.VisualBasic.Syntax.TryBlockSyntax TryBlock (Microsoft.CodeAnalysis.VisualBasic.Syntax.TryStatementSyntax tryStatement, Microsoft.CodeAnalysis.SyntaxList<Microsoft.CodeAnalysis.VisualBasic.Syntax.StatementSyntax> statements, Microsoft.CodeAnalysis.SyntaxList<Microsoft.CodeAnalysis.VisualBasic.Syntax.CatchBlockSyntax> catchBlocks, Microsoft.CodeAnalysis.VisualBasic.Syntax.FinallyBlockSyntax finallyBlock, Microsoft.CodeAnalysis.VisualBasic.Syntax.EndBlockStatementSyntax endTryStatement);
static member TryBlock : Microsoft.CodeAnalysis.VisualBasic.Syntax.TryStatementSyntax * Microsoft.CodeAnalysis.SyntaxList<Microsoft.CodeAnalysis.VisualBasic.Syntax.StatementSyntax> * Microsoft.CodeAnalysis.SyntaxList<Microsoft.CodeAnalysis.VisualBasic.Syntax.CatchBlockSyntax> * Microsoft.CodeAnalysis.VisualBasic.Syntax.FinallyBlockSyntax * Microsoft.CodeAnalysis.VisualBasic.Syntax.EndBlockStatementSyntax -> Microsoft.CodeAnalysis.VisualBasic.Syntax.TryBlockSyntax
Public Shared Function TryBlock (tryStatement As TryStatementSyntax, statements As SyntaxList(Of StatementSyntax), catchBlocks As SyntaxList(Of CatchBlockSyntax), finallyBlock As FinallyBlockSyntax, endTryStatement As EndBlockStatementSyntax) As TryBlockSyntax

Parámetros

tryStatement
TryStatementSyntax

Instrucción "Try" que comienza el bloque "Try".

statements
SyntaxList<StatementSyntax>

Lista de instrucciones que se van a ejecutar.

catchBlocks
SyntaxList<CatchBlockSyntax>

Lista de bloques "Catch" que se pueden ejecutar si se produce una excepción al ejecutar las instrucciones en el bloque "Try".

finallyBlock
FinallyBlockSyntax

Un bloque "Finally" que se va a ejecutar antes de que la ejecución deje el bloque "Try".

endTryStatement
EndBlockStatementSyntax

Instrucción "End Try".

Devoluciones

Se aplica a

TryBlock()

Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb

Representa un elemento "Try ... Atrapar... Finalmente... Finalizar bloque Try".

public:
 static Microsoft::CodeAnalysis::VisualBasic::Syntax::TryBlockSyntax ^ TryBlock();
public static Microsoft.CodeAnalysis.VisualBasic.Syntax.TryBlockSyntax TryBlock ();
static member TryBlock : unit -> Microsoft.CodeAnalysis.VisualBasic.Syntax.TryBlockSyntax
Public Shared Function TryBlock () As TryBlockSyntax

Devoluciones

Se aplica a

TryBlock(SyntaxList<StatementSyntax>, SyntaxList<CatchBlockSyntax>, FinallyBlockSyntax)

Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb

Representa un elemento "Try ... Atrapar... Finalmente... Finalizar bloque Try".

public:
 static Microsoft::CodeAnalysis::VisualBasic::Syntax::TryBlockSyntax ^ TryBlock(Microsoft::CodeAnalysis::SyntaxList<Microsoft::CodeAnalysis::VisualBasic::Syntax::StatementSyntax ^> statements, Microsoft::CodeAnalysis::SyntaxList<Microsoft::CodeAnalysis::VisualBasic::Syntax::CatchBlockSyntax ^> catchBlocks, Microsoft::CodeAnalysis::VisualBasic::Syntax::FinallyBlockSyntax ^ finallyBlock);
public static Microsoft.CodeAnalysis.VisualBasic.Syntax.TryBlockSyntax TryBlock (Microsoft.CodeAnalysis.SyntaxList<Microsoft.CodeAnalysis.VisualBasic.Syntax.StatementSyntax> statements, Microsoft.CodeAnalysis.SyntaxList<Microsoft.CodeAnalysis.VisualBasic.Syntax.CatchBlockSyntax> catchBlocks, Microsoft.CodeAnalysis.VisualBasic.Syntax.FinallyBlockSyntax finallyBlock);
static member TryBlock : Microsoft.CodeAnalysis.SyntaxList<Microsoft.CodeAnalysis.VisualBasic.Syntax.StatementSyntax> * Microsoft.CodeAnalysis.SyntaxList<Microsoft.CodeAnalysis.VisualBasic.Syntax.CatchBlockSyntax> * Microsoft.CodeAnalysis.VisualBasic.Syntax.FinallyBlockSyntax -> Microsoft.CodeAnalysis.VisualBasic.Syntax.TryBlockSyntax
Public Shared Function TryBlock (statements As SyntaxList(Of StatementSyntax), catchBlocks As SyntaxList(Of CatchBlockSyntax), finallyBlock As FinallyBlockSyntax) As TryBlockSyntax

Parámetros

statements
SyntaxList<StatementSyntax>

Lista de instrucciones que se van a ejecutar.

catchBlocks
SyntaxList<CatchBlockSyntax>

Lista de bloques "Catch" que se pueden ejecutar si se produce una excepción al ejecutar las instrucciones en el bloque "Try".

finallyBlock
FinallyBlockSyntax

Un bloque "Finally" que se va a ejecutar antes de que la ejecución deje el bloque "Try".

Devoluciones

Se aplica a