Monday, July 16, 2007

Mid function in VB.net for C# Guys

Hi C# Devs,

I want to convert one of the vb.net code functions to a c# solution for some requirments ,i found on the code the usage of Mid function as one of the important functions on the string manipulation for vb.net developers; as a C# guy,i need an equivelant to it,simply replace the mid function with the following :

VB.Net :
str2= Mid(str1, 1, Len(str1) - 1)
C# :
str2=str1.substring(1);


substring function is the equivelant to Left,Right,Mid functions for VB.Net developers.

VIVA C#.................. :)


Regards,
Moustafa arafa

No comments: