Date in Win 2K server

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi ,

What the date that is displayed on the command prompt is not the same when I
set it in the Control panel = > Input Locales..

If I change the date on the control panel => input locales to dd/mm/yyyy
(portuguese Brazilian), it shows correct, but in a few minutes in a command
prompt the date returns to mm/dd/yyyy (US format) when i type date command.

Can anyone help me cause I have an application that gets the system date,
but the date must be in a dd/mm/yyyy format.

Thank's

Junio
 
Here is a batch file that sets %%a to the month, %%b to the day, and %%c to
the year. Hope this helps...

@echo off
setlocal
for /f "tokens=2-4 delims=/ " %%a in ('date /t') do set xdate=%%b-%%a-%%c
echo.
echo Date = %xdate%
endlocal
pause >nul
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top