'What assembly to get application properties?
I have example code that looks like this, but I can't figure out where assembly to include to get Properties ?
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Configuration;
using System.Reflection;
using System.Windows;
using System.Windows.Forms;
using System.Drawing;
namespace ScreenSizeEntity
{
class ScreenSize
{
public void Resize(Form scrn)
{
if (System.Diagnostics.Debugger.IsAttached)
{
Normal(scrn);
}
else
{
Maximise(scrn);
}
}
public void Maximise(Form scrn, bool MaximiseOverride = false)
{
scrn.Text = "";
scrn.FormBorderStyle = FormBorderStyle.None;
scrn.WindowState = FormWindowState.Maximized;
scrn.Height = Screen.PrimaryScreen.Bounds.Height;
scrn.Width = Screen.PrimaryScreen.Bounds.Width;
if (!MaximiseOverride)
Properties.Settings.Default.IsMaximised = true;
Properties.Settings.Default.Save();
scrn.Invalidate();
Application.DoEvents();
scrn.TopMost = true;
scrn.Activate();
}
...
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
