🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: borland.public.cppbuilder.nativeapi
6 messages
6 total messages Started by Vladimir Grigoriev Fri, 24 Mar 2006 15:06
About date format in XP command line window
#4053
Author: Vladimir Grigoriev
Date: Fri, 24 Mar 2006 15:06
14 lines
1641 bytes
Hi
Sorry if this is not the newsgroup where I should to ask my question. But I
don't know the *right* newsgroup.
In Windows XP in Control Panel -> Date, Time, Language, and Regional
Options -> Change the format of numbers, dates, and times you can customize
date format by changing "Short date format", for example, from dd.MM.yyyy to
dd.MM.yy and vice verse. Consequently when you will issue DOS command DIR
file date will be displayed accordingly i.e. as dd.MM.yyyy or dd.MM.yy.
My question is what is a (new) DOS int 21h service that can allow me to
determine what date format currently is used? Well-known DOS service 38h and
6501h don't report this information. They tell only about American,
European, and Japan date representation.

Vladimir Grigoriev
Re: About date format in XP command line window
#4056
Author: Andrue Cope [TeamB]
Date: Fri, 24 Mar 2006 15:43
17 lines
1466 bytes
Vladimir Grigoriev wrote:

> My question is what is a (new) DOS int 21h service that can allow me
> to determine what date format currently is used?

What makes you think you are running the MS-DOS 'DIR' command?

A 'DOS box' is actually no such thing. It's a Win32 console and you are
running the Win32 application 'cmd.exe'. It's just that this recognises
DOS applications when you ask it to run them and it creates a VDM for
them to run inside then performs the neccessary magic to integrate this
into the user console 'experience' almost seamlessly.

-- 
Andrue Cope [TeamB]
[Bicester, Uk]
http://info.borland.com/newsgroups/guide.html
Re: About date format in XP command line window
#4055
Author: Vladimir Grigoriev
Date: Fri, 24 Mar 2006 15:55
24 lines
1839 bytes
Thanks Andrue for information.
However what about my question? Is any DOS service that allows to determine
the date format currently in use on XP?
Vladimir Grigoriev

"Andrue Cope [TeamB]" <no.spam@not.a.valid.address> wrote in message
news:442413ae$1@newsgroups.borland.com...
> Vladimir Grigoriev wrote:
>
> > My question is what is a (new) DOS int 21h service that can allow me
> > to determine what date format currently is used?
>
> What makes you think you are running the MS-DOS 'DIR' command?
>
> A 'DOS box' is actually no such thing. It's a Win32 console and you are
> running the Win32 application 'cmd.exe'. It's just that this recognises
> DOS applications when you ask it to run them and it creates a VDM for
> them to run inside then performs the neccessary magic to integrate this
> into the user console 'experience' almost seamlessly.
>
> -- 
> Andrue Cope [TeamB]
> [Bicester, Uk]
> http://info.borland.com/newsgroups/guide.html
Re: About date format in XP command line window
#4057
Author: Andrue Cope [TeamB]
Date: Fri, 24 Mar 2006 15:59
17 lines
1579 bytes
Vladimir Grigoriev wrote:

> Is any DOS service that allows to determine
> the date format currently in use on XP?

I don't know but by definition it wouldn't be part of the Win32 API.
Or..hmm. Try asking in .non-technical.

It's technically possible for such a call to exist but an entirely
different matter as to whether it does. MS have never seemed too
interested in integrating DOS applications into Windows. We should
probably be grateful they can even share clipboards :-/

-- 
Andrue Cope [TeamB]
[Bicester, Uk]
http://info.borland.com/newsgroups/guide.html
Re: About date format in XP command line window
#4058
Author: Vladimir Grigoriev
Date: Fri, 24 Mar 2006 16:03
7 lines
1286 bytes
Thanks. I will try at once!
Vladimir Grigoriev

"Andrue Cope [TeamB]" <no.spam@not.a.valid.address> wrote in message
news:4424176d@newsgroups.borland.com...
> I don't know but by definition it wouldn't be part of the Win32 API.
> Or..hmm. Try asking in .non-technical.
Re: About date format in XP command line window
#4060
Author: Remy Lebeau (TeamB)
Date: Fri, 24 Mar 2006 19:57
17 lines
1501 bytes
"Vladimir Grigoriev" <vlad.moscow@mail.ru> wrote in message
news:44240adb@newsgroups.borland.com...

> My question is what is a (new) DOS int 21h service that can
> allow me to determine what date format currently is used?

Since a DOS box is a Win32 console, not a true DOS session, you can use
Win32 API functions in console applications.  Use GetLocaleInfo() to
retreive locale-specific formats.

If you are using the VCL, then it already retreives many locale formats at
startup and stores them into global variables, such as the "ShortDateFormat"
variable.


Gambit
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads