【问题标题】:Winforms: Wait Cursor with info-textWinforms:带有信息文本的等待光标
【发布时间】:2012-05-16 09:17:46
【问题描述】:

是否有可能在等待光标旁边显示一个小的信息文本。这是一个不错的功能,可以在用户等待期间向用户提供一些活动信息。

【问题讨论】:

    标签: c# .net winforms cursor


    【解决方案1】:

    是的。您必须在鼠标位置旁边使用标签。只需尝试以下代码:

    private void pictureBox1_MouseEnter(object sender, EventArgs e)
            {
                pictureBox1.Cursor = Cursors.WaitCursor;
                Label lb = new Label();
                lb.Location = new Point(MousePosition.X-this.Left,MousePosition.Y-this.Top);
                lb.Text = "Your Info";
                this.Controls.Add(lb);
    
            }
    

    【讨论】:

      【解决方案2】:

      我建议使用自定义光标。 C# Tutorial - How To Use Custom Cursors

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 2018-06-08
        • 2010-12-06
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        相关资源
        最近更新 更多