+ Reply to Thread
Results 1 to 2 of 2

Worksheet TextBox

  1. #1
    Registered User
    Join Date
    04-09-2015
    Location
    London, England
    MS-Off Ver
    2010
    Posts
    30

    Worksheet TextBox

    Hi all,

    I have a worksheet with a textbox which will be used to allow the user to put a date in for a search mechinism but i only want a specific format in the box

    Is there a way i can only get the user to put in what i need to capture. For example

    TextBox1 is for date capture and the format is dd-mm-yyy and the - in between is also important

    Something like if textbox1.value is not dd-mm-yyyy then

    Msg box wrong

    Else

    Do thing

    End if

    Thanks all and help appreciated

  2. #2
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS 365 Family 64-bit 2404
    Posts
    24,858

    Re: Worksheet TextBox

    See attached. There is quite a bit of error checking necessary to make sure you have a valid date.
    Attached Files Attached Files
    Jeff
    | | |會 |會 |會 |會 | |:| | |會 |會
    Read the rules
    Use code tags to [code]enclose your code![/code]

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Multi-Worksheet ActiveX Textbox to ActiveX Textbox Concatenate
    By HVE_Skynet in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-21-2014, 02:11 PM
  2. Replies: 4
    Last Post: 01-29-2014, 05:53 AM
  3. VBA - Macro Code to copy textbox text to another worksheet textbox
    By nitram lowm in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 02-05-2013, 08:39 AM
  4. Macro to copy textbox data to a duplicate textbox in another worksheet
    By nitram lowm in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 02-02-2013, 06:10 AM
  5. Userform to search textbox value to place other textbox values in worksheet
    By mattyh555 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 09-19-2012, 11:38 AM

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1