Make sure first letter is uppercase

Discussion in 'ASP General' started by Middletree, Jul 12, 2007.

  1. Middletree

    Middletree Guest

    I want to take a value that users type into a field (actually 2
    fields--first and last name) and convert the first letter to Upper Case. I
    htought I could use UCase, but it seems to only work for an entire string.
    Anyone got a suggestion?
     
    Middletree, Jul 12, 2007
    #1
    1. Advertising

  2. Middletree

    Evertjan. Guest

    Middletree wrote on 12 jul 2007 in
    microsoft.public.inetserver.asp.general:

    > I want to take a value that users type into a field (actually 2
    > fields--first and last name) and convert the first letter to Upper
    > Case. I htought I could use UCase, but it seems to only work for an
    > entire string. Anyone got a suggestion?


    t = request.form("myField")
    t = ucase(left(t,1)) & mid(t,2)

    --
    Evertjan.
    The Netherlands.
    (Please change the x'es to dots in my emailaddress)
     
    Evertjan., Jul 12, 2007
    #2
    1. Advertising

  3. Middletree

    Middletree Guest

    Works! Thanks!
     
    Middletree, Jul 13, 2007
    #3
  4. Middletree

    Evertjan. Guest

    Middletree wrote on 13 jul 2007 in microsoft.public.inetserver.asp.general:

    > Works! Thanks!


    Please next time, quote. Usenet is not email!

    --
    Evertjan.
    The Netherlands.
    (Please change the x'es to dots in my emailaddress)
     
    Evertjan., Jul 13, 2007
    #4
  5. Middletree

    Middletree Guest

    > Middletree wrote on 13 jul 2007 in
    > microsoft.public.inetserver.asp.general:
    >
    >> Works! Thanks!

    >
    > Please next time, quote. Usenet is not email!


    And Microsoft forums are not Usenet.

    I hate quoting because I am a staunch believer in top-posting, and when I
    quote, I get "corrected" by those who hate top-posting. They always remind
    me that top-posting is against the rules of etiquitte. In fact, most people
    I know prefer to read a top-posted message, but because we weren't around
    newsgroups in 1989 when those rules were formulated, we don't get any say.

    But I bottom-posted here for you because I really appreciate your help. I
    had never heard of "mid" before. Thanks.
     
    Middletree, Jul 13, 2007
    #5
  6. Middletree

    Evertjan. Guest

    Middletree wrote on 13 jul 2007 in
    microsoft.public.inetserver.asp.general:

    >> Middletree wrote on 13 jul 2007 in
    >> microsoft.public.inetserver.asp.general:
    >>
    >>> Works! Thanks!

    >>
    >> Please next time, quote. Usenet is not email!

    >
    > And Microsoft forums are not Usenet.


    Any NG that is on usenet is part of usenet.

    > I hate quoting because I am a staunch believer in top-posting, and
    > when I quote, I get "corrected" by those who hate top-posting. They
    > always remind me that top-posting is against the rules of etiquitte.
    > In fact, most people I know prefer to read a top-posted message, but
    > because we weren't around newsgroups in 1989 when those rules were
    > formulated, we don't get any say.
    >
    > But I bottom-posted here for you because I really appreciate your
    > help. I had never heard of "mid" before. Thanks.


    OK.


    --
    Evertjan.
    The Netherlands.
    (Please change the x'es to dots in my emailaddress)
     
    Evertjan., Jul 13, 2007
    #6
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. shapper
    Replies:
    3
    Views:
    695
    George Ter-Saakov
    Nov 1, 2006
  2. Nacho

    first letter to uppercase

    Nacho, Apr 5, 2004, in forum: ASP General
    Replies:
    3
    Views:
    120
    Evertjan.
    Apr 5, 2004
  3. Dave Angel
    Replies:
    0
    Views:
    149
    Dave Angel
    Oct 20, 2012
  4. Zero Piraeus
    Replies:
    0
    Views:
    151
    Zero Piraeus
    Oct 20, 2012
  5. Dennis Lee Bieber

    Re: change the first letter into uppercase (ask)

    Dennis Lee Bieber, Oct 20, 2012, in forum: Python
    Replies:
    0
    Views:
    153
    Dennis Lee Bieber
    Oct 20, 2012
Loading...

Share This Page