Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Occurs in C#
Message
De
26/02/2013 13:05:53
 
 
Information générale
Forum:
ASP.NET
Catégorie:
Code, syntaxe and commandes
Titre:
Versions des environnements
Environment:
C# 4.0
OS:
Windows 7
Network:
Windows 2003 Server
Database:
MS SQL Server
Divers
Thread ID:
01566946
Message ID:
01566948
Vues:
49
>Hi everybody,
>
>Just wondering if occurs should be implemented the same way as in SQL Server?
>
>E.g.
>
>string.Length - String.replace(stringToTest,"").Length
>


What's wrong with String.Contains() ? Why do you need a replace()



>
>Thanks in advance.
>
>Found this implementation also
>
>http://www.dotnetperls.com/string-occurrence
>
>wondering if I should go with my first idea or this one.
>
>Found this discussion
>
>http://stackoverflow.com/questions/541954/how-would-you-count-occurences-of-a-string-within-a-string-c
>
>I think I may need two separate methods - one for string and one for char.
Gregory
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform