Share via


Information.SystemTypeName(String) Método

Definición

Devuelve un valor de tipo String que contiene el nombre del tipo de datos del sistema de una variable.

public:
 static System::String ^ SystemTypeName(System::String ^ VbName);
public static string? SystemTypeName (string? VbName);
public static string SystemTypeName (string VbName);
static member SystemTypeName : string -> string
Public Function SystemTypeName (VbName As String) As String

Parámetros

VbName
String

Obligatorio. Variable de String que contiene un nombre de tipo de Visual Basic.

Devoluciones

Devuelve un valor de tipo String que contiene el nombre del tipo de datos del sistema de una variable.

Ejemplos

En el ejemplo siguiente se usa la SystemTypeName función para devolver nombres de tipo de datos para varias variables.

Dim vbLongName As String = "Long"
Dim vbDateName As String = "Date"
Dim vbBadName As String = "Number"
Dim testSysName As String
testSysName = SystemTypeName(vbLongName)
' The preceding call returns "System.Int64".
testSysName = SystemTypeName(vbDateName)
' The preceding call returns "System.DateTime".
testSysName = SystemTypeName(vbBadName)
' The preceding call returns Nothing.

Comentarios

SystemTypeName devuelve el nombre de tipo completo de Common Language Runtime (CLR) correspondiente al nombre de tipo de Visual Basic. Por ejemplo, si VbName contiene "Date", SystemTypeName devuelve "System.DateTime". Si SystemTypeName no reconoce el valor de VbName, devuelve Nothing (no la cadena "Nothing").

Se aplica a

Consulte también