Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Strange String Comparisons
Message
De
06/01/2004 20:00:42
Keith Payne
Technical Marketing Solutions
Floride, États-Unis
 
 
À
06/01/2004 15:27:24
Information générale
Forum:
ASP.NET
Catégorie:
Autre
Divers
Thread ID:
00864339
Message ID:
00864450
Vues:
11
Keith,

I guess that the literal strings are not cast into full fledged string objects by the CLR when there is no property or method access in the code.

What is the result if the object appears on the right side of the expression?

>Has anyone seen this? :
>
>Dim case_no as string = "04"
>
>In the VS debugger,
>
>? "04" < "30" returns True
>
>? case_no < "30" returns False
>
>Using the StrComp function, though, works as expected whether you use a literal string or a variable on the left hand side of the comparison.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform