more basic

  Josquius 18:29 16 Apr 2004
Locked

Can anyone direct me to somewhere I can find out about how all of this left ,mid and right stuff works in basic?
It really has me puzzled and I need to get it working, I have stuff like
If Mid(temp, char, 1) > "." Then
and I'm not entirely sure what any of it means...

  VoG II 19:00 16 Apr 2004

Which sort of Basic? Do you mean Visual Basic for Applications (VBA) or "real" Visual Basic?

  VoG II 19:30 16 Apr 2004

If Mid(temp, char, 1) > "." doesn't make any sense.

Left(string, num)

returns a string of length num from the left of string.

Right(string, num)

returns a string of length num from the right side of string

Mid(string, num1, num2) returns a string of length num2 from a string, beginning at position num1 of the string.

  Josquius 21:42 16 Apr 2004

It is in excel.
It doesn't make any sense? Hmm could explain why it doesn't work.

  VoG II 21:50 16 Apr 2004

Mid("Josquious", 2, 3)

will return "osq"

Is this greater than "." ?

Is not a sensible comparison, is it.

Please take a step back and tell us what you are trying to do.

  Josquius 12:31 18 Apr 2004

Its seperating blocks of writing into different lines where it goes onto a new line when it hits a full stop. I have seen similar things working elsewhere though can't get it to work myself.

  VoG II 12:38 18 Apr 2004

You would need to use

For char = 1 to len(temp)

If Mid(temp, char, 1) = "." Then

'start a new line

Exit For

End If

Next char

This thread is now locked and can not be replied to.

Elsewhere on IDG sites

OnePlus 5 review

See the work of famous artists playing with toys

iPad Pro 10.5in (2017) review

Comment faire une capture d’écran sur un Mac ?