Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Detecting null value on Integer
Message
De
24/01/2016 04:57:39
 
 
À
23/01/2016 14:25:51
Information générale
Forum:
ASP.NET
Catégorie:
Code, syntaxe and commandes
Versions des environnements
Environment:
VB 9.0
OS:
Windows 8.1
Network:
Windows 2008 Server
Database:
MS SQL Server
Application:
Web
Divers
Thread ID:
01630133
Message ID:
01630141
Vues:
54
>I have this to detect a null value on a string:
>
>
>        ' If we have a value
>        If Not tcValue Is DBNull.Value Then
>            lcString = Trim(tcValue)
>        End If
>
>
>Using such an approach for an integer won't work because Is operator cannot be used against an integer.
>
>What would be an easier solution?

Are you confusing .NET data types with SqlDbType - DBNull.Value only applies to SQL types.... ?
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform