Shandy's Blog

Where Andrew Sutton, aka Shandy rants and rambles on as the fancy takes him

vbCity Blogs moved to:
http://cs.vbcity.com/blogs
  Home :: Syndication  :: Login

My name is Andrew Sutton, aka Shandy.

I am currently living and working in the UK as a software developer. This blog contains mainly IT related issues.

I was a Microsoft VB MVP for a couple of years (Apr 2004-Mar 2006) and was a vbCityLeader between April 2003 and June 2007.

If you are looking for my Sri Lanka or Morocco experiences check out Shandy's Sri Lanka Blog or Shandy's Morocco Blog. My personal (Non IT) blog is now at Shandy's Place

OctNovember 2009Dec
SMTWTFS
25262728293031
1234567
891011121314
15161718192021
22232425262728
293012345

Articles

Archives

Topics

Image Galleries

.NET

Blogs I Read

Others

VB.Classic

I am in the process of writing a VB.Classic application that will convert VB Code into HTML code so that it is nicely formatted. E.g.

Private Function FindNumberOfUniqueCharactersInString(ByVal strVvText As String _
                                                     , ByVal blnVvCaseSensitive As Boolean _
                                                     ) As Integer
    Dim intLvIndex As Integer
    Dim intLvCount As Integer: intLvCount = 1
    strVvText = IIf(blnVvCaseSensitive, strVvText, UCase$(strVvText))
    For intLvIndex = 2 To Len(strVvText)
        If InStr(Left(strVvText, intLvIndex - 1) _
                , Mid(strVvText, intLvIndex, 1) _
                ) = 0 Then
            intLvCount = intLvCount + 1
        End If
    Next
    FindNumberOfUniqueCharactersInString = intLvCount
End Function

becomes

Private Function FindNumberOfUniqueCharactersInString(ByVal strVvText As String _
                                                     , ByVal blnVvCaseSensitive As Boolean _
                                                     ) As Integer
    Dim intLvIndex As Integer
    Dim intLvCount As Integer: intLvCount = 1
    strVvText = IIf(blnVvCaseSensitive, strVvText, UCase$(strVvText))
    For intLvIndex = 2 To Len(strVvText)
        If InStr(Left(strVvText, intLvIndex - 1) _
                , Mid(strVvText, intLvIndex, 1) _
                ) = 0 Then
            intLvCount = intLvCount + 1
        End If
    Next
    FindNumberOfUniqueCharactersInString = intLvCount
End Function

When I have completed the application I will post it at vbCity. As you can see from the above code (created using my application) the basics are working. I just need to allow the application to know about more reserved words, perform more testing, and correct any bugs the testing shows up and then it will be ready.

posted on Tuesday, July 19, 2005 9:46 PM