Results 1 to 5 of 5
  1. #1
    Join Date
    Oct 2003
    Location
    London
    Posts
    341

    Question Unanswered: Reporting in Sentance Case Format

    I currently have an access report that reports on comments made in the case that they were typed in.

    I know that in the Format property if I type > then it will report in UPPERCASE, whilst < will report in lowercase, but is there any way that I can report in sentance case... I.e. First letter of the string is UPPERCASE whilst the rest is lower.

    Regards

  2. #2
    Join Date
    Jul 2004
    Posts
    64
    You might could use one of the string functions such as Left() to get the first letter in a line, then you could apply the case formatting to just that letter.

  3. #3
    Join Date
    Oct 2003
    Location
    London
    Posts
    341
    Yeah, I thought that would be possible to but so far I have been unable get that to work.

    The problem is that the place you input the format (see attached) doesn't allow you to build an expression and I don't know enough to write the format in VB.

    Thanks for your suggestion though.
    Attached Thumbnails Attached Thumbnails Image.gif  
    Last edited by christyxo; 07-27-04 at 11:03. Reason: Forgot attachment

  4. #4
    Join Date
    Jul 2004
    Posts
    64
    Try this out.. Let me know if you have problems figuring out where to put the code:

    [CODE]
    Dim myStr As String
    Dim myStrCase As String
    Dim myStrLetter As String
    Dim myStrRest As String
    Dim myStrLength As Integer


    myStr = Me.mytext
    myStrLength = Len(myStr)
    myStrLetter = UCase(Left(myStr, 1))
    myStrRest = Right(myStr, myStrLength - 1)
    myStrCase = myStrLetter & myStrRest

    'The msgbox's below just demonstrate the process as it happened
    'You would need to use your own code to populate a text box
    'MsgBox myStrLetter
    'MsgBox myStrRest
    'MsgBox myStrCase

  5. #5
    Join Date
    Oct 2003
    Location
    London
    Posts
    341
    Hey!

    Needing your help again. Where do I put this code?

Posting Permissions

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