Computing.Net > Forums > Programming > About short date format

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Click here to start participating now! Also, check out the New User Guide.

About short date format

Reply to Message Icon

Name: vlad.moscow
Date: March 29, 2006 at 05:07:37 Pacific
OS: Windows XP, DOS
CPU/Ram: Intel
Comment:

Is there any way to know a DOS program short date format on Windows XP?




Sponsored Link
Ads by Google

Response Number 1
Name: StuartS
Date: March 29, 2006 at 06:13:44 Pacific
Reply:

As there is no DOS in Windows XP, you question has no relevance.

The date format produced at the command prompt is determined by the regional settings you set in Windows.

Stuart


0

Response Number 2
Name: vlad.moscow
Date: March 30, 2006 at 02:23:09 Pacific
Reply:

Thanks StuartS
But as I know the rigonal settings are present also in Windows 3.11. Moreover there is such DOS environment constant that can be used in BAT files as %date% which correctly (according to the XP regional settings) shows date.
So I think there should be either DOS Int 21h service or other feature that allows to get short date format.
I'd like to have this feature very much!


0

Response Number 3
Name: Mechanix2Go
Date: March 30, 2006 at 03:03:45 Pacific
Reply:

What do you mean by "DOS short date"?


If at first you don't succeed, you're about average.

M2


0

Response Number 4
Name: StuartS
Date: March 30, 2006 at 04:09:00 Pacific
Reply:

I do not not know if there is an Int 21h service in the Windows XP command prompt, probably not.

Int 21 made direct access to the hardware. Windows XP does not allow direct access to the hardware by an application, it has to go through the relevant driver, usually via an APO call. That is why a lot of DOS applications do not work under Windows XP.

THERE IS NO DOS IN WINDOWS XP!

Stuart


0

Response Number 5
Name: Mechanix2Go
Date: March 30, 2006 at 22:44:35 Pacific
Reply:

Hi Stuart,

INT 21 is alive and well under NT5.

See my:

http://computing.net/programming/wwwboard/forum/14133.html



If at first you don't succeed, you're about average.

M2


0

Related Posts

See More



Response Number 6
Name: vlad.moscow
Date: March 31, 2006 at 01:21:12 Pacific
Reply:

>Mechanix2Go
>What do you mean by "DOS short date"?
I mean that in Windows you can set short date format. For example on XP you can do this by selecting Control Panel -> Date, Time, Language, and Regional Options -> Change the format of numbers, dates, and times -> Regional Options -> Customize -> Date
If you will do these all DOS commands (or emulated DOS commands)will aware about current date setting.
Unfortunately well-known Int 21h functions (38h and 6501h) return only date separator and date type (American, Eoropean, Japan). They nothing say about two or four digits used in date format. You should not forget that regional settings appear in Windows before XP.
>StuartS
>That is why a lot of DOS applications do >not work under Windows XP.
I think this statement is wrong. Only those DOS applications do not work under Windows XP which uses BIOS dependant features or try to get DOS servirces without using Int 21h.
I write myself much DOS code on assembler which is running on XP without any problem. Even if I try directly access BIOS for video services (as I can guess XP emulates also some BIOS functions) nothing wrong happens.
I have MS DOS programming guide which contains a very full description of DOS 5.0 interrupts functions. But I have not such guide for DOS 6.XX and even DOS 7->. I think new servirces shold be added with appearance new versions of Windows (as for example Long File Names servirces). But not much information is published my Microsoft.
In any case to be consistent with Windows regional settings DOS should have a way to access these settings (and it is consistent!).


0

Response Number 7
Name: Mechanix2Go
Date: March 31, 2006 at 03:23:33 Pacific
Reply:

Hi vlad,

OK now I'm with you.

It must be in the registry.

But I have no idea where.


If at first you don't succeed, you're about average.

M2


0

Sponsored Link
Ads by Google
Reply to Message Icon

looking for a script... batch file



Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Programming Forum Home


Sponsored links

Ads by Google


Results for: About short date format

Change Date Format in XP www.computing.net/answers/programming/change-date-format-in-xp/16292.html

VB6 - Date format www.computing.net/answers/programming/vb6-date-format/12131.html

Batch file to append created date www.computing.net/answers/programming/batch-file-to-append-created-date/14993.html