Hi All, just wondering if you can help me out.
Basically this is what I have so far.
Some sample text:
@RISK 4.5 for Excel
@RISK 5.5 Industrial for Excel
@RISK 5.5 Standard for Excel
@RISK for Excel, Standard Network Edition
@RISK Standard 5.5.1
Now while my script does strip out the version number if they are in the middle it doesn't work if they are at the end. Also I can't figure out what if the number is stupidly at the start...grrr.
Thanks in advance,
John
Basically this is what I have so far.
Code:
Sub StripOutVersionNum()
Count = 2
Sheets("Sheet2").Select
Do While Range("A" & Count) <> ""
StringName = Range("A" & Count).Value
FindDot = InStr(1, StringName, ".",)
If FindDot > 0 Then
NewStringFirstWord = (Left(StringName, (InStr(FindDot - 2, StringName, " "))))
NewStringSecondWord = (Mid(StringName, (InStr(FindDot, StringName, " ") + 1), Len(StringName)))
Range("B" & Count).Value = NewStringFirstWord & NewStringSecondWord
End If
Count = Count + 1
Loop
End Sub
Some sample text:
@RISK 4.5 for Excel
@RISK 5.5 Industrial for Excel
@RISK 5.5 Standard for Excel
@RISK for Excel, Standard Network Edition
@RISK Standard 5.5.1
Now while my script does strip out the version number if they are in the middle it doesn't work if they are at the end. Also I can't figure out what if the number is stupidly at the start...grrr.
Thanks in advance,
John