⬆️ ⬇️

Windows API Code Pack for .NET Framework

Recently, the Windows API Code Pack 1.0.1 library has been released. This is not a major update with many new features, but rather a version aimed at correcting errors, increasing productivity, adding examples and updating several functions (new shells, etc.).



But before we delve into the new version of the Windows Code Pack, let's look at what it is.



Windows 7 offers such new features as, for example, a taskbar, libraries, the Sensor and Location platform. These functions assume new scenarios and provide developers with new features in order to better adapt their applications for Windows 7. All these functions are available through the Win32 API. There is currently no “Windows 7” namespace in the .NET Framework, and there is also no easy way to use these functions from applications written in managed code. To make it easier for developers using managed code to access them, in August we released the 1.0 version of the Windows API Code Pack for the .NET Framework (immediately after Windows 7 RTM).

')

The Windows API Code Pack is a free managed source library provided by Microsoft as is. You should treat it as if you wrote it yourself, as if it were your own code. It covers many of the new features of Windows 7, as well as some of the most important features of Windows Vista. You can consider the Windows API Code Pack thing closest to the "official" managed API for Windows. But keep in mind that Microsoft support does not provide support for this 24x7 product. We believe that this is a great solution and that the code base is very reliable and of high quality.







Our goal with the Code Pack is to allow developers using managed code to take advantage of programmable Windows interfaces that are not part of the .NET Framework. It seems to us that, as a public source code, the Windows API Code Pack, separate from the .NET runtime libraries, provides the best compromise between Microsoft Win32 and the managed shell. It should be noted a short development cycle - we released the Windows API Code Pack just a month after Win7 RTM; In addition, we release the full source code of the library.



The Windows API Code Pack includes a large number of managed APIs for Windows (7). For example:





Each technology introduced in the Windows API Code Pack is accompanied by a series of demonstrations and examples (including source codes) in C # and VB. We are planning to release updates for the Windows API Code Pack approximately every three months. We will work on stability (i.e. bug fixes), the core of the package, testing and documentation, as well as support for new features (focusing on customer feedback).



You may ask yourself: “Why is the Windows API Code Pack not part of the .NET Framework?”



We are releasing open source, which we can include in the execution environment in the future, if the further growth of its size will be justified. Remember that the .NET Framework works on both Windows Vista and Windows XP. However, Windows 7 is already here, and we want to provide access to this free, open source suite earlier, not later. We are releasing the library in the form in which it is required by the community and, as you can see, we intend to update it in the future. While this version (1.0.1) is a minor update, we are planning a new release over the next few months. In the meantime, you are taking advantage of both measurements in a package that you can use in whole or in part without any restrictions.



Another question you can ask: “Will the .NET 4 need eliminate the use of the Windows API Code Pack?”



When .NET 4 comes out, you can use its Windows 7-related functions in areas such as the taskbar, the integration of multi-touch devices with WPF, support for DirectWrite, and the location API via the Devices namespace. Other functions, such as libraries, Restart Manager and Sensors, will continue to be accessed through the Windows API Code Pack.



Finally, we expect community feedback — from you .NET developers who use this library to write Windows 7-driven applications on the managed code. On the Windows Code Pack API Windows Web site , you can ask a question, provide feedback, report bugs and follow for open bugs. Your participation is very important for the continued existence of this library, so please send us your feedback and questions.



To learn more about how to use the Windows API Code Pack, check out the Windows 7 training on Channel 9 .

Source: https://habr.com/ru/post/78678/



All Articles