给出例子 学哥 学姐们 帮帮忙啊
c# winform 怎么制作滚动文字啊
- 提问者网友:心牵心
- 2021-05-22 08:12
- 五星知识达人网友:一叶十三刺
- 2021-05-22 08:19
bool Fx = false;//标示方向
private void timer1_Tick(object sender, EventArgs e)
{
if (button13.Left + button13.Width < 0)
{
button13.Left = button13.Left + 1;
Fx = true;
}
else
{
if (button13.Left < this.Width)
{
if (Fx)
{
button13.Left = button13.Left + 1;
}
else
{
button13.Left = button13.Left - 1;
}
}
else if (button13.Left == this.Width)
{
Fx = false;
button13.Left = button13.Left - 1;
}
}
}