Win32Methods 1.5.0

dotnet add package Win32Methods --version 1.5.0                
NuGet\Install-Package Win32Methods -Version 1.5.0                
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Win32Methods" Version="1.5.0" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Win32Methods --version 1.5.0                
#r "nuget: Win32Methods, 1.5.0"                
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install Win32Methods as a Cake Addin
#addin nuget:?package=Win32Methods&version=1.5.0

// Install Win32Methods as a Cake Tool
#tool nuget:?package=Win32Methods&version=1.5.0                

This Package is not meant for using a native methods, it uses the methods that are from win32 librarys. and make it more easier, so you can modify your window properties more easily instead of P/Invoke. If you downloaded it, Thank you very much for downloading it! However, there is an important note, when you call an property or a method, in this version, it may throw an exception because some imported functions can not be found. before start, there is one step only to do to make the package working perfectly:

Change your net version to net-windows because this package is only compatible with windows. (Sure because it uses methods from windows).

Now you can start working! if you don't what to do, type using Win32Methods; (the namespace of this package). you can see four namespaces in it: Windows, Exceptions, System Let's start with Window class: // here we are using a namespace from Win32Methods.NativeWindow; using Win32Methods.NativeWindow; // and we declaring a new variable of Window class. And using the console handle from NativeConsole class because our application is console. if we didn't used it will not work! Use the current constructor if the application is not console. Window app = NativeConsole.ConsoleHandle; // and we set the title of this application to "Hello, world" // However it is a console, so if it reclicked and moved it will back to default. app.Title = "Hello, world!"; // and we set the size of the application to 800, 600 pixels. // The first one is the width size of the window, and the second one is the height size of the window. app.Size = new(800, 600); // we flashing the window with default enum value. app.Flash(); // and we focusing the window to the top. app.Focus(); // and we wait for the application to exit. app.WaitForExit(); // And that's all for today.

Product Compatible and additional computed target framework versions.
.NET net7.0-windows7.0 is compatible.  net8.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net7.0-windows7.0

    • No dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.5.0 356 5/28/2023
1.4.2 223 3/30/2023
1.3.6 237 3/12/2023
1.3.2 275 2/19/2023
1.3.0 265 2/16/2023
1.2.0 261 2/4/2023
1.1.7 259 2/1/2023
1.1.3 266 1/31/2023
1.1.0 280 1/29/2023
1.0.8 281 1/28/2023
1.0.3 277 1/23/2023
1.0.2 269 1/23/2023
1.0.0 310 1/23/2023