A
Animal via OfficeKB.com
Hi,
I have two problems:
1. I'm doing a general template. All the workstations are having the default
language for the format DATE set to Swedish, but I have to have it in English.
I have created a custom list containing "jan, feb, mar, apr, may, jun, jul,
aug, sep, oct, nov, dec" on my computer but this does not apply when I change
computer. When I for example switch computer and do an autofill it comes out
in Swedish.
How can I secure that I get the DATE format series in english?
2. The second problem continues in this problem, but can maybe be solved if
the first problem is, or? I have to do some calulations with a DATE variable,
to basically add a month to a variable.
Here is my code:
Dim reportdateOk As Date
reportdateOk = Range("ReportYear") & "-" & Range("ReportMonth") ex: (2007-
05-01)
reportdateOk2 = DateAdd("m", 1, reportdateOk)
ex: (2007-06-01)
This workes perfectly if I use Swedish months or months that are the same in
the swedish language (all months except for "maj" and "okt"), but not when I
use English months, because the variable reportDateOK is a DATE-variable and
it is programmed for Swedish.
Can someone please help me?
Thanks in advance!
/Animal
I have two problems:
1. I'm doing a general template. All the workstations are having the default
language for the format DATE set to Swedish, but I have to have it in English.
I have created a custom list containing "jan, feb, mar, apr, may, jun, jul,
aug, sep, oct, nov, dec" on my computer but this does not apply when I change
computer. When I for example switch computer and do an autofill it comes out
in Swedish.
How can I secure that I get the DATE format series in english?
2. The second problem continues in this problem, but can maybe be solved if
the first problem is, or? I have to do some calulations with a DATE variable,
to basically add a month to a variable.
Here is my code:
Dim reportdateOk As Date
reportdateOk = Range("ReportYear") & "-" & Range("ReportMonth") ex: (2007-
05-01)
reportdateOk2 = DateAdd("m", 1, reportdateOk)
ex: (2007-06-01)
This workes perfectly if I use Swedish months or months that are the same in
the swedish language (all months except for "maj" and "okt"), but not when I
use English months, because the variable reportDateOK is a DATE-variable and
it is programmed for Swedish.
Can someone please help me?
Thanks in advance!
/Animal