+ Reply to Thread
Results 1 to 2 of 2

Date format changing between cell and textbox

  1. #1
    Registered User
    Join Date
    01-17-2011
    Location
    Wiltshire, England
    MS-Off Ver
    Excel 2007
    Posts
    36

    Date format changing between cell and textbox

    Hi All

    I use the code below to populate a textbox from a work sheet, the Cell B12 has the date in dd/mm/yyyy format and I have set the textbox to change this to dd.mm.yyyy.

    Please Login or Register  to view this content.
    This works ok for most of the time but today the cell was showing 05/07/2011 and the textbox was showing 07.05.2011. Im sure i'm missing something very simple but not sure what it is.

    Can anyone help me please ??

    Thanks for looking

    Processchip

  2. #2
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,496

    Re: Date format changing between cell and textbox

    I've got a feeling that it will be using American format dates. I'd be inclined to take the separate elements of the date using DAY, MONTH and YEAR and then rebuild the date in the format required (rather than trying to do it in one/two step/s).

    Regards
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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