怎样设置窗口靠右,并且高度屏幕的高度一样

解决方案 »

  1.   

    设置Form的属性
    this.Top = 0;
    this.Height = Screen.PrimaryScreen.WorkingArea.Height;
    this.Left = Screen.PrimaryScreen.WorkingArea.Width - this.Width;
      

  2.   

    设置窗口的Location,Position属性?最大最小化?
      

  3.   

    关键还是理解Screen.PrimaryScreen
      

  4.   


    int x = Screen.PrimaryScreen.Bounds.Width - this.Width;
    int y = 0;
    this.Location = new Point(x, y);
    this.Height = Screen.PrimaryScreen.Bounds.Height;
      

  5.   


    this.Top = 0;
    this.Height = Screen.PrimaryScreen.WorkingArea.Height;
    this.Left = Screen.PrimaryScreen.WorkingArea.Width - this.Width;这个是靠右。。你再试试。是不是哪弄错了