Consulting

Results 1 to 6 of 6

Thread: names in text box

  1. #1
    VBAX Regular MUSASHI's Avatar
    Joined
    Oct 2004
    Location
    Corpus Christi, Texas (Very South)
    Posts
    44

    names in text box

    as part of my ongoing little "project", part of the data required on a userform is username. It is entered into a textbox.

    Is there a way to force the entry to be as follows :

    nameTextBox= firstname;lastname

    the semicolon makes it easy to manipulate later on as required as we have so many silly external "projects" requiring the name in various configurations..

    If they fail to enter it correctly, it wont accept it is a must, maybe a msg box saying "You are a momo", Enter First Name, Semicolon(,then Last Name

    I can figure out some of this, but some I am clueless!

    Thanks a lot!
    Musashi!

  2. #2
    Site Admin
    Jedi Master
    VBAX Guru Jacob Hilderbrand's Avatar
    Joined
    Jun 2004
    Location
    Roseville, CA
    Posts
    3,712
    Location
    Try something like this:

    Option Explicit
    
    Private Sub TextBox1_AfterUpdate()
    If InStr(1, Me.TextBox1.Text, ";") > 0 Then
            'ok
        Else
            MsgBox "You forgot the ;"
        End If
    End Sub

  3. #3
    VBAX Regular MUSASHI's Avatar
    Joined
    Oct 2004
    Location
    Corpus Christi, Texas (Very South)
    Posts
    44
    thanks, as usual. I will post this thing sometime this weekend....if its appropriate?

    first ever attempt at a "project"

    appreciate the help.

    Mus

  4. #4
    Site Admin
    Jedi Master
    VBAX Guru Jacob Hilderbrand's Avatar
    Joined
    Jun 2004
    Location
    Roseville, CA
    Posts
    3,712
    Location
    Sure. Post it so we can all have a look.

    Glad to help

    Take Care

  5. #5
    VBAX Regular MUSASHI's Avatar
    Joined
    Oct 2004
    Location
    Corpus Christi, Texas (Very South)
    Posts
    44
    here ya go man. Im getting stuck fast...the more I figure out...the more I dont know how to do...heheh

    time entry sheet...MD helped me not start the intersect until after 12 rows....how to make stop at 52, or 53?

    going have a couple other major problems too..hehe the time entry sheet is for 1 day....going to have potentially 7 days...probably just make a time entry sheet for each day...

    how to save the "timesheet", the values at that point in time?

    how to summarize all 7 sheets?

    One thing about it....this stuff is fun..

    any guidance appreciated

  6. #6
    Site Admin
    Jedi Master
    VBAX Guru Jacob Hilderbrand's Avatar
    Joined
    Jun 2004
    Location
    Roseville, CA
    Posts
    3,712
    Location
    Quote Originally Posted by MUSASHI
    how to make stop at 52, or 53?
    If Target.Row() > 12 And Target.Row() < 53 Then

    So this would run for rows 13-52.

Posting Permissions

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