i




 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
VB Left function alternative in c#
03-01-2013, 05:41 PM
Post: #1
VB Left function alternative in c#
Left function exist in vb.net but there is no left function in c#
but we can achive the same functionality in c# by using Substring function of string

Code:
string result = Value.Substring(0, length);

like
Code:
string Value = "dotnetobject";
string result =  Value.Substring(0, 6);

Result:
dotnet



[Image: 2604595733.png]
Quote




User(s) browsing this thread: 1 Guest(s)