本文介绍了C#没有可拖动形式的areo的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这是我的代码

This is my code

Point lastClicked;
  private void Form1_MouseDown(object sender, MouseEventArgs e)
  {
      lastClicked = e.Location;
  }

  private void Form1_MouseUp(object sender, MouseEventArgs e)
  {

  }


  private void Form1_MouseMove(object sender, MouseEventArgs e)
  {
      if (e.Button == MouseButtons.Left)
      {
          this.Left += e.X - lastClicked.X;
          this.Top += e.Y - lastClicked.Y;
      }
  }



当我将窗体向上拖动时,areo不能在Windows 7中与from一起使用,并且我希望它在我的可拖动窗体上执行areo,此外,还请您解释一下为什么它不能执行areo的问题?

areo = when i drag the from up to the top of my screen the from maximizes



When I drag my form up the areo doesn''t work in windows 7 with the from, and i would like it to do the areo on my drag-able form, plus can some please explain why it doesn''t do the areo?

areo = when i drag the from up to the top of my screen the from maximizes

推荐答案



这篇关于C#没有可拖动形式的areo的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-12 18:55