+ Reply to Thread
Results 1 to 2 of 2

show text-date as a result of named field formula

  1. #1
    Registered User
    Join Date
    03-10-2011
    Location
    Sunava, Slovakia
    MS-Off Ver
    Excel 2003
    Posts
    4

    show text-date as a result of named field formula

    Hi, I'm stuck with a problem.

    In our software we keep some data as named field values. As we had some problems with various regional settings, we decided to tweak up the way on how the formulas are stored.

    Let's say I call my Named field "DoJob", To make date culture-invariant I put in there something like =DATE(2010,1,1) ..so far so good, but when I set value of the cell to "DoJob", only excel date number is shown [40176]... I know, this could be easily resolved by bhanging cell format, BUT...our software is used by average-to below-average computer users that got confused when suddenly instead of date a 5-digit number was shown, so this is not an option.

    I know I could do something like =TEXT(DATE(2010,1,1),"my desired format") ... BUT [why there always has to be one ?? ] that destroys the whole idea of culture-invariance, thus I would like to ask to the best of the best...

    Reason for all this - we have some report-templates that use excel functions such as YEAR, MONTH, etc., which don't work when adapted to different culture

    Is there a way I could achieve string [text] representation of current date without specifying the exact format and without using VBA macro ? ...something like =TEXT(DATE(2010,1,1),"currentCulture")

    Any help would be strongly appreciated,
    Piplislav Pindol

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

    re: show text-date as a result of named field formula

    Welcome to the Forum!

    The named field aspect is a red herring. I have attached something that shows how to format a date based on selection of a "culture" but you have to set up a table defining what cultures you want and what formats to use. See if this helps.
    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)

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