Solved

vb.net left$, Mid$ now what

Posted on 2004-08-27
1
316 Views
Last Modified: 2010-04-17
I am use to using left$, mid$ in vb6. I now notice that in vb.net it doesn't work

I know that if I use
Imports VB = Microsoft.VisualBasic

and then vb.left$

it works, but what is the equilvent in vb.net. I mean they have to still have something that does the left$, mid$ - right????


0
Comment
Question by:bear23
1 Comment
 
LVL 11

Accepted Solution

by:
coopzz earned 25 total points
ID: 11913119
Public Function Substring(ByVal startIndex As Integer) As String
Public Function Substring(ByVal startIndex As Integer, ByVal length As Integer) As String

ie: equ to left(s, 5)

dim s as string = "the beast"
msgbox s.substring( 4 )

will alert with "Beast".

this page will give you some comparisons with these things
http://www.ondotnet.com/pub/a/dotnet/2001/07/30/vb7.html?page=2

cheers
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
groupSum6 challenge 6 77
groupSumClump challenge 9 103
How can i compile this github project?? 2 77
how to use laptop or pad camera in vb.net windows application 2 55
This article will show, step by step, how to integrate R code into a R Sweave document
Entering a date in Microsoft Access can be tricky. A typo can cause month and day to be shuffled, entering the day only causes an error, as does entering, say, day 31 in June. This article shows how an inputmask supported by code can help the user a…
An introduction to basic programming syntax in Java by creating a simple program. Viewers can follow the tutorial as they create their first class in Java. Definitions and explanations about each element are given to help prepare viewers for future …
In this fifth video of the Xpdf series, we discuss and demonstrate the PDFdetach utility, which is able to list and, more importantly, extract attachments that are embedded in PDF files. It does this via a command line interface, making it suitable …

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

23 Experts available now in Live!

Get 1:1 Help Now