Board index » delphi » Windows Unit - What's it good for ?

Windows Unit - What's it good for ?

I have looked in all the indexes and through all the helpfiles, but I
can't find any reference to the Windows unit which Delphi always adds
as to the "Uses" line.

Is there anybody who have the knowledge to answer me ?

---------------------------------------------------------------------
Johan F. ?hman                  joh...@sn.no
  Norway
* Manager of the famous Essay Exchange page:
------  Http://www.sn.no/~johanf/  ----------------------------------

 

Re:Windows Unit - What's it good for ?


In article u...@hasle.sn.no, joh...@sn.no (Johan Fredrik ?hman) writes:

Quote
>I have looked in all the indexes and through all the helpfiles, but I
>can't find any reference to the Windows unit which Delphi always adds
>as to the "Uses" line.

It is probably because the Windows unit does not really exist.
"Windows" in this case is an alias to multiple other units.
Wintype and Winprocs I believe (off the top of my head).  So
the Windows unit would be documented in the Wintype and
Winprocs units.

Delphi 2 introduced this new alias technique for units.
Somewhere in the Project|Options menu you can see what unit
aliases you really have.

Best regards,
Michael Vincze
vin...@ti.com

Re:Windows Unit - What's it good for ?


joh...@sn.no (Johan Fredrik ?hman) wrote:

Quote
>I have looked in all the indexes and through all the helpfiles, but I
>can't find any reference to the Windows unit which Delphi always adds
>as to the "Uses" line.
>Is there anybody who have the knowledge to answer me ?

This unit declares a lot of  data types you need for programming. In
fact this unit is the interface to the Windows-API with all procedures
and data types declared in it.
You may get your project to work without using any procedure, but a
lot of data types are common to the API and the VCL, so they are
declared there.

If you want to test it, just remove the unit from the uses clause and
watch how far you come.

Uhhh, just forgot. It declares a lot of constants, too.

Hope this helps

Meik Weber
m.we...@public.ndh.com or
100744.3...@compuserve.com

Re:Windows Unit - What's it good for ?


Quote
>I have looked in all the indexes and through all the helpfiles, but I
>can't find any reference to the Windows unit which Delphi always adds
>as to the "Uses" line.

        In 2.0 WINDOWS is the rough equivalent of WINPROCS and WINTYPES combined.

_
******************************************************************
NOTE: This software is currently in early alpha. If you notice any
problems, or RFC non-compliance, please report it to p...@pbe.com
 \------------------------------------------------------------\
  \           Chad Z. Hower  -  phoe...@pobox.com              \
   \  Phoenix Business Enterprises - p...@pbe.com - www.pbe.com  \
    \     Physically in Church Hill, TN - Logically Not Sure     \
     \------------------------------------------------------------\

Quote
>>SQUID - The ultimate 95/NT offline databasing reader

**Special Compile: 3.000A (Alpha)

Re:Windows Unit - What's it good for ?


    Thank You very much for taking your time answering my questions !!

---------------------------------------------------------------------
Johan F. ?hman                  joh...@sn.no
  Norway
* Manager of the famous Essay Exchange page:
------  Http://www.sn.no/~johanf/  ----------------------------------

Re:Windows Unit - What's it good for ?


On 27 Jun 1996 15:42:28 GMT, vin...@ti.com (Michael Vincze) wrote:

Quote
>In article u...@hasle.sn.no, joh...@sn.no (Johan Fredrik ?hman) writes:

>>I have looked in all the indexes and through all the helpfiles, but I
>>can't find any reference to the Windows unit which Delphi always adds
>>as to the "Uses" line.

>It is probably because the Windows unit does not really exist.
>"Windows" in this case is an alias to multiple other units.
>Wintype and Winprocs I believe (off the top of my head).  So
>the Windows unit would be documented in the Wintype and
>Winprocs units.

Actually, it's the other way around. In D2, there is a single unit,
Windows. Delphi defines the aliases, WinTypes and WinProcs to be
equivalent to Windows, for backward compatibility. D1 has two separate
units.
--
Ray Lischner                              li...@tempest-sw.com
Tempest Software, Corvallis, Oregon, USA  http://www.tempest-sw.com

Re:Windows Unit - What's it good for ?


Johan Fredrik ?hman (joh...@sn.no) wrote:
: I have looked in all the indexes and through all the helpfiles, but I
: can't find any reference to the Windows unit which Delphi always adds
: as to the "Uses" line.

: Is there anybody who have the knowledge to answer me ?

It is in the delphi 2.0\sources\rtl\win directory.

Other Threads