Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Casting Question
Message
Information générale
Forum:
ASP.NET
Catégorie:
Code, syntaxe and commandes
Titre:
Casting Question
Divers
Thread ID:
01458169
Message ID:
01458169
Vues:
103
In this example, pRecordId is an instance of a SqlParameter class.

This works
int RetVal = Convert.ToInt32(pRecordId.Value);
This throws "Specified cast is not valid"
int RetVal = (int)pRecordId.Value;
Why?
Everything makes sense in someone's mind
public class SystemCrasher :ICrashable
In addition, an integer field is not for irrational people
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform