Results 1 to 2 of 2
  1. #1
    Join Date
    Apr 2003
    Posts
    1

    Question Unanswered: Library for Proper/Upper/Lower

    I need to know the library for Proper Case

    tmphold = Proper(RecSet!LastName)
    Seems that the tools/References does not have the proper library cheked off. Can anyone help please.

    Thanks

  2. #2
    Join Date
    Apr 2003
    Location
    Santa Barbara, CA
    Posts
    67

    Re: Library for Proper/Upper/Lower

    Originally posted by Sylvia
    I need to know the library for Proper Case

    tmphold = Proper(RecSet!LastName)
    Seems that the tools/References does not have the proper library cheked off. Can anyone help please.

    Thanks
    Stick this in one of your Modules.

    Function Proper(fld As String) As String
    Dim z%
    fld = Trim(fld)
    fld = UCase(Left(fld, 1)) & LCase(Mid(fld, 2))
    If InStr(fld, " ") Then
    For z% = 2 To Len(fld)
    If Asc(Mid(fld, z%, 1)) = 32 Then
    fld = Left(fld, z%) + UCase(Mid(fld, z% + 1, 1)) + Mid(fld, z% + 2)
    End If
    Next
    End If
    Proper = fld
    End Function

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •