如何以编程方式在Windows Mobile 6上显示等待图标?
这应该很容易做,但我不能谷歌它,因为有太多的等待图标替换在那里…:-)
谢谢,
禤浩焯
发布于 2010-07-22 20:43:22
下面这样的代码可能会有些用处:
class WaitCursor : IDisposable
{
public WaitCursor()
{
Cursor.Current = Cursors.WaitCursor;
}
public void Dispose()
{
Cursor.Current = Cursors.Default;
}
}它允许您使用"using“块返回到默认光标,即使您有一个异常或返回:
public Foo()
{
using (var c = new WaitCursor())
{
// do long-running stuff
// when we exit the using block, the cursor will return to the default state
}
}发布于 2010-07-22 20:22:01
你是说等待光标?
using System.Windows.Forms;
Cursor.Current = Cursors.WaitCursor;https://stackoverflow.com/questions/3306277
复制相似问题