VBA's Equivalent of VBScript's SetLocale 
Author Message
 VBA's Equivalent of VBScript's SetLocale

Hi,

Does anyone know the VBA equivalents to the following VBScripting
functions:-

    SetLocale - Sets the global locale and returns the previous locale and,
    GetLocale  - Returns the current locale ID value.

I need to do something similar to the following in VBA

Sub Button1_onclick
  Dim original
  original = SetLocale("en-gb")
  mydate = CDate(UKDate.value)
  ' IE always sets the locale to US English so use the
  ' currentLocale variable to set the locale to US English
  original = SetLocale(currentLocale)
  USDate.value = FormatDateTime(mydate,vbShortDate)
End Sub

Thanks in Advance,
AO



Tue, 08 Mar 2005 18:51:19 GMT  
 VBA's Equivalent of VBScript's SetLocale
This is the VB.Net newsgroup.  You are better off posting to the appropriate
newsgroup.  VBA and VB.Net are significantly different.

Your are more likely to get a good responce here:
microsoft.public.office.developer.vba

Michael

Quote:

> Hi,

> Does anyone know the VBA equivalents to the following VBScripting
> functions:-

>     SetLocale - Sets the global locale and returns the previous locale
and,
>     GetLocale  - Returns the current locale ID value.

> I need to do something similar to the following in VBA

> Sub Button1_onclick
>   Dim original
>   original = SetLocale("en-gb")
>   mydate = CDate(UKDate.value)
>   ' IE always sets the locale to US English so use the
>   ' currentLocale variable to set the locale to US English
>   original = SetLocale(currentLocale)
>   USDate.value = FormatDateTime(mydate,vbShortDate)
> End Sub

> Thanks in Advance,
> AO



Wed, 09 Mar 2005 00:14:30 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. VBA's Equivalent of VBScript's SetLocale

2. 'through account' VBA equivalent

3. JScript's UTC method equivalent in VBScript

4. vbscript equivalent to javascript's escape() function ??

5. VB equivalent of vbscript's EXECUTE method

6. Function equivalent to VBScript's Eval

7. VBA equivalent to GWBASIC's MKI$ ?

8. VB's equivalent voor VBA function: IsObjectValid

9. VBA equivalent to GWBASIC's MKI$ ?

10. VBScript 'private'/'public'

11. Word Equivalent to 'CountIf'

12. Word equivalent to 'Countif'

 

 
Powered by phpBB® Forum Software