+ Reply to Thread
Results 1 to 6 of 6

Using VBA to temporarily bypass regional options

  1. #1
    Carim
    Guest

    Using VBA to temporarily bypass regional options

    Hi all,

    Is there an elegant way of temporarily asking VBA to stick to its
    embedded US core settings, in order to format dates accordingly ...,
    and then, once action has been performed, to return to its regional
    settings ...

    Thanks for all your comments
    Cheers
    Carim


  2. #2
    Bob Phillips
    Guest

    Re: Using VBA to temporarily bypass regional options

    Doesn't it already do that? It is certainly my understanding.

    --
    HTH

    Bob Phillips

    (remove nothere from email address if mailing direct)

    "Carim" <carim.fam@wanadoo.fr> wrote in message
    news:1141893655.302948.326710@u72g2000cwu.googlegroups.com...
    > Hi all,
    >
    > Is there an elegant way of temporarily asking VBA to stick to its
    > embedded US core settings, in order to format dates accordingly ...,
    > and then, once action has been performed, to return to its regional
    > settings ...
    >
    > Thanks for all your comments
    > Cheers
    > Carim
    >




  3. #3
    Carim
    Guest

    Re: Using VBA to temporarily bypass regional options

    Bob,

    What I am facing is a French based environment, which needs to trigger
    a English report to HQ ...
    Format(Date,"mmmm") produces in French mars ...
    whereas my objective is to have it show March ...
    So far, I have cheated quite inelegantly... ans as wondering if a
    couple of instructions could help me temporarily bypass the French
    settings ...

    Thanks for your comments
    Carim


  4. #4
    Bob Phillips
    Guest

    Re: Using VBA to temporarily bypass regional options

    Carim,

    I see the problem now.

    An alternative would be, instead of putting the result in the cell as you
    are doing now, put a formula, For instance

    Activecell.Formula = "=TEXT(TODAY(),""mmmm"")"

    This will have the effect of creating formula that an English version will
    interpret as March, and a French version will interpret as Mars.


    --
    HTH

    Bob Phillips

    (remove nothere from email address if mailing direct)

    "Carim" <carim.fam@wanadoo.fr> wrote in message
    news:1141909799.783769.236420@v46g2000cwv.googlegroups.com...
    > Bob,
    >
    > What I am facing is a French based environment, which needs to trigger
    > a English report to HQ ...
    > Format(Date,"mmmm") produces in French mars ...
    > whereas my objective is to have it show March ...
    > So far, I have cheated quite inelegantly... ans as wondering if a
    > couple of instructions could help me temporarily bypass the French
    > settings ...
    >
    > Thanks for your comments
    > Carim
    >




  5. #5
    Carim
    Guest

    Re: Using VBA to temporarily bypass regional options

    Bob,

    I already knew this world was unfair ... But now, I am terribly jealous
    ....

    Your suggestion is simply brilliant !!! ... because it is brilliantly
    simple ...!!!

    Thanks a lot
    All the Best

    Carim


  6. #6
    Bob Phillips
    Guest

    Re: Using VBA to temporarily bypass regional options

    <G> Glad we could help.

    Bob

    "Carim" <carim.fam@wanadoo.fr> wrote in message
    news:1141913123.216727.307340@i40g2000cwc.googlegroups.com...
    > Bob,
    >
    > I already knew this world was unfair ... But now, I am terribly jealous
    > ...
    >
    > Your suggestion is simply brilliant !!! ... because it is brilliantly
    > simple ...!!!
    >
    > Thanks a lot
    > All the Best
    >
    > Carim
    >




+ 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