What are Basics  of visual programing ?

In C#, input devices and resources can be accessed using the System.Windows.Forms and System.IO namespaces.

visual Programing basics


To interact with keyboard, you can use the following classes:

  • Keyboard: Provides properties for determining the state of the keyboard and its keys.
  • KeyEventArgs: Provides data for the KeyDown and KeyUp events.

To interact with mouse, you can use the following classes:

  • Cursor: Provides properties for interacting with the cursor, such as setting its position and visibility.
  • MouseEventArgs: Provides data for the MouseMove, MouseDown, and MouseUp events.

To access files and directories, you can use classes from System.IO namespace like File, Directory, FileStream, and StreamReader etc.Additionally, you can also use the System.Windows.Input namespace for more advanced input handling, such as using gestures and touch input.

It's worth noting that depending on the use case, you may want to use different libraries, like DirectInput or XInput, to interact with gamepads and joysticks.


E Learning

window management in c#

In C#, windows can be managed using the System.Windows.Forms namespace, which provides classes for creating and interacting with windows, buttons, text boxes, and other common user interface elements. The main class for creating a window is the Form class, which can be subclassed to create custom windows. The Form class provides methods for showing and hiding the window, as well as for handling user input and events such as button clicks. Additionally, the System.Windows.Controls namespace provides classes for creating more complex user interfaces using WPF (Windows Presentation Foundation).