devel-windows.rst
changeset 685 6413021852a2
parent 663 07f96799cb19
parent 684 0ac1323ba715
child 686 68e738cda3a0
equal deleted inserted replaced
663:07f96799cb19 685:6413021852a2
     1 -*- mode: outline -*-
       
     2 
       
     3 * Dependency Walker.
       
     4 
       
     5 Dependency Walker is a free utility that scans any 32-bit or 64-bit Windows
       
     6 module (exe, dll, ocx, sys, etc.) and builds a hierarchical tree diagram of
       
     7 all dependent modules. For each module found, it lists all the functions that
       
     8 are exported by that module, and which of those functions are actually being
       
     9 called by other modules. Another view displays the minimum set of required
       
    10 files, along with detailed information about each file including a full path
       
    11 to the file, base address, version numbers, machine type, debug information,
       
    12 and more.
       
    13 
       
    14 See
       
    15 
       
    16   http://www.dependencywalker.com/
       
    17 
       
    18 * Windows 2000 Resource Kit Tools.
       
    19 
       
    20   http://support.microsoft.com/kb/927229
       
    21                 Windows 2000 Resource Kit Tools for administrative tasks
       
    22 
       
    23 * Sysinternals.
       
    24 
       
    25 TODO
       
    26 
       
    27 * Application verifier.
       
    28 
       
    29   http://www.microsoft.com/downloads/en/details.aspx?familyid=c4a25ab9-649d-4a1b-b4a7-c9d8b095df18
       
    30                 download page
       
    31   http://msdn.microsoft.com/en-us/library/ms220948.aspx
       
    32                 Application Verifier
       
    33 
       
    34 * Running at startup.
       
    35 
       
    36   HKCU\Software\Microsoft\Windows\CurrentVersion\Run
       
    37                 Launches a program automatically when a particular user logs
       
    38                 in. This key is used when you always want to launch a program
       
    39                 when a particular user is using a system.
       
    40   HKCU\Software\Microsoft\Windows\CurrentVersion\RunOnce
       
    41                 Launches a program the next time the user logs in and removes
       
    42                 its value entry from the registry. This key is typically used
       
    43                 by installation programs.
       
    44   HKLM\Software\Microsoft\Windows\CurrentVersion\Run
       
    45                 Launches a program automatically at system startup. This key
       
    46                 is used when you always want to launch a program on a
       
    47                 particular system.
       
    48   HKLM\Software\Microsoft\Windows\CurrentVersion\RunOnce
       
    49                 Launches a program the next time the system starts and removes
       
    50                 its value entry from the registry. This key is typically used
       
    51                 by installation programs.
       
    52   HKLM\Software\Microsoft\Windows\CurrentVersion\RunServices
       
    53                 Launches a service (a standard NT service or a background
       
    54                 process) automatically at startup. An example of a service is
       
    55                 a Web server such as Microsoft Internet Information Server.
       
    56   HKLM\Software\Microsoft\Windows\CurrentVersion\RunServicesOnce
       
    57                 Launches a service (a standard NT service or a background
       
    58                 process) the next time the system is started, then removes its
       
    59                 value entry from the registry.
       
    60 
       
    61 Values to registry on Windows XP can be added by:
       
    62 
       
    63   cmd> reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Run" /v run.bat /t REG_SZ /d "path\to\run.bat"
       
    64   cmd> reg query HKCU\Software\Microsoft\Windows\CurrentVersion\Run   <-- see what done
       
    65 
       
    66 * MFC.
       
    67 
       
    68 ** Can I link to MFC statically.
       
    69 
       
    70 Yes.
       
    71 
       
    72   http://msdn.microsoft.com/en-us/library/f22wcbea%28VS.80%29.aspx
       
    73 
       
    74 * Microsoft Visual C++ Redistributable Package.
       
    75 
       
    76   http://www.microsoft.com/downloads/en/confirmation.aspx?familyId=32bc1bee-a3f9-4c13-9c99-220b62a191ee&displayLang=en
       
    77                 This package installs runtime components of C Runtime (CRT),
       
    78                 Standard C++, ATL, MFC, OpenMP and MSDIA libraries.
       
    79 
       
    80 * Cabinet file (.cab).
       
    81 
       
    82   http://support.microsoft.com/kb/198038
       
    83                 INFO: Useful Tools for Package and Deployment Issues
       
    84   http://msdn.microsoft.com/en-us/library/aa367841%28VS.85%29.aspx
       
    85                 The Makecab.exe utility is included in the Windows SDK
       
    86                 Components for Windows Installer Developers.
       
    87   http://web.archive.org/web/20070403215326/http://download.microsoft.com/download/platformsdk/cab/2.0/w98nt42kmexp/en-us/cabsdk.exe
       
    88                 download link from web archive
       
    89   http://msdn.microsoft.com/en-us/library/aa370834%28v=VS.85%29.aspx
       
    90                 The components of the Windows Installer Software Development
       
    91                 Kit are included in the Microsoft Windows Software Development
       
    92                 Kit (SDK).
       
    93   http://msdn.microsoft.com/en-us/library/bb417343.aspx
       
    94                 Microsoft Cabinet Format
       
    95 
       
    96 * Internet Explorer.
       
    97 
       
    98 ** Debugging.
       
    99 
       
   100 Install IE 8.0 and press 'F12' key.
       
   101 
       
   102   http://msdn.microsoft.com/library/dd565626.aspx
       
   103                 Developer Tools User Interface Reference
       
   104 
       
   105 * Microsoft technologies.
       
   106 
       
   107 ** COM.
       
   108 
       
   109 The family of COM technologies includes COM+, Distributed COM (DCOM) and ActiveX® Controls.
       
   110 
       
   111   http://www.microsoft.com/com/default.mspx
       
   112                 home page
       
   113 
       
   114 ** OLE.
       
   115 
       
   116 OLE (Object Linking and Embedding) allows embedding and linking to documents and other objects.
       
   117 
       
   118 OLE 1.0 released in 1990, OLE 2.0 released in 1993, in 1994 OLE custom controls (OCXs) were
       
   119 introduced.
       
   120 
       
   121 OLE objects and containers are implemented on top of the Component Object Model.
       
   122 
       
   123 Next release after 2.0 introdused in 1996 and named as ActiveX.
       
   124 
       
   125   http://en.wikipedia.org/wiki/Object_Linking_and_Embedding
       
   126 
       
   127 ** ActiveX.
       
   128 
       
   129 Faced with the complexity of OLE 2.0 and with poor support for COM in MFC, Microsoft rationalized
       
   130 the specifications to make them simpler, and rebranded the technology as ActiveX in 1996.
       
   131 
       
   132   http://msdn.microsoft.com/en-us/library/aa751968.aspx
       
   133                 ActiveX Controls
       
   134   http://en.wikipedia.org/wiki/ActiveX
       
   135 
       
   136 ** ATL.
       
   137 
       
   138 The Active Template Library (ATL) is a set of template-based C++ classes developed by Microsoft,
       
   139 intended to simplify the programming of Component Object Model (COM) objects.
       
   140 
       
   141   http://en.wikipedia.org/wiki/Active_Template_Library
       
   142 
       
   143 ** MFC.
       
   144 
       
   145 MFC (Microsoft Foundation Classes) is a library that wraps portions of the Windows API in C++
       
   146 classes, including functionality that enables them to use a default application framework. Classes
       
   147 are defined for many of the handle-managed Windows objects and also for predefined windows and
       
   148 common controls.
       
   149 
       
   150 A lightweight alternative to MFC is the Windows Template Library (WTL).
       
   151 
       
   152   http://en.wikipedia.org/wiki/Microsoft_Foundation_Class_Library
       
   153   http://ru.wikipedia.org/wiki/Microsoft_Foundation_Classes
       
   154 
       
   155 ** WTL.
       
   156 
       
   157 WTL (Windows Template Library) is a free software, object-oriented C++ template library for Win32
       
   158 development.
       
   159 
       
   160 WTL provides support for implementing various user interface elements, to MDI, standard and common
       
   161 controls, common dialogs, property sheets and pages, GDI objects, and other common UI elements, such
       
   162 as scrollable windows, splitter windows, toolbars and command bars.
       
   163 
       
   164 Most of the WTL API is a mirror of the standard Win32 calls.
       
   165 
       
   166   http://sourceforge.net/projects/wtl
       
   167   http://en.wikipedia.org/wiki/Windows_Template_Library
       
   168 
       
   169 * Windows style variable names.
       
   170 
       
   171   Prefix   |  Data type
       
   172   ---------+-----------------------------------------
       
   173   b        |  boolean
       
   174   by       |  byte or unsigned char
       
   175   c        |  char
       
   176   cx / cy  |  short used as size
       
   177   dw       |  DWORD, double word or unsigned long
       
   178   fn       |  function
       
   179   h        |  handle
       
   180   i        |  int (integer)
       
   181   l        |  Long
       
   182   n        |  short int
       
   183   p        |  a pointer variable containing the address of a variable
       
   184   s        |  string
       
   185   sz       |  ASCIIZ null-terminated string
       
   186   w        |  WORD unsigned int
       
   187   x, y     |  short used as coordinates
       
   188 
       
   189   PrefixCategory  | Mean
       
   190   ----------------+----------------
       
   191   CS              | Class style
       
   192   CW              | Create window
       
   193   DT              | Draw text
       
   194   IDC             | Cursor ID
       
   195   IDI             | Icon ID
       
   196   WM              | Window message
       
   197   WS              | Window style
       
   198 
       
   199   Data type | Meaning
       
   200   ----------+-------------------------------------------------------------------
       
   201   FAR       | Same as far. Identifies an address that originally used the
       
   202             | segment:offset addressing schema. Now FAR simply identifies a
       
   203             | (default) 32-bit address but may be omitted entirely in many cases.
       
   204             |
       
   205   PASCAL    | Same as Pascal. The Pascal convention demanded by Windows
       
   206             | defines the order in which arguments are found in the stack when
       
   207             | passed as calling parameters.
       
   208             |
       
   209   WORD	    | Unsigned integer (16 bits)
       
   210             |
       
   211   UINT      | Unsigned integer, same as WORD
       
   212             |
       
   213   DWORD     | Double word, unsigned long int (32 bits)
       
   214             |
       
   215   LONG      | Signed long integer (32 bits)
       
   216             |
       
   217   LPSTR     | Long (far) pointer to character string
       
   218             |
       
   219   NEAR      | Obsolete, previously identified an address value within a 16KB
       
   220             | memory block.
       
   221 
       
   222   http://www.tenouk.com/cnotation.html
       
   223                 C/C++ NOTATION STORY