Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
C# substring
Message
 
 
À
Tous
Information générale
Forum:
ASP.NET
Catégorie:
Code, syntaxe and commandes
Titre:
C# substring
Versions des environnements
Environment:
C# 4.0
OS:
Windows 7
Network:
Windows 2003 Server
Database:
MS SQL Server
Divers
Thread ID:
01572787
Message ID:
01572787
Vues:
82
Hi everybody,

I have this method
internal void GetDCIComponents(String tcDCI, out String department, out String category, out String item)
      {
         department = tcDCI.Substring(0, 10);
         category = tcDCI.Substring(10, 10);
         item = tcDCI.Substring(20, 10);
      }
The problem is with the last assignment when I pass item less than 10 characters. What is the best way to "simulate" VFP substring to get up to the length of the item?

Thanks in advance.
If it's not broken, fix it until it is.


My Blog
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform