使用MSAgent代替传统的MessageBox提示来增用客户端用户体验

        以往的应用程序我们大多都是使用MessageBox来给用户以反馈,不免显得有点呆板,使用MSAgent来改善客户端的用户体验:



传统的提示方法:

使用MSAgent的提示方法:

代码:

            axAgent2.Characters.Load("Role",Application.StartupPath+"\\Assistant\\"+"earl.acs");
            axAgent2.Characters[
"Role"].Show(null);
            axAgent2.Characters[
"Role"].Activate(null);
            axAgent2.Characters[
"Role"].SoundEffectsOn=true;
            axAgent2.Characters[
"Role"].Top=200;
            axAgent2.Characters[
"Role"].Left=300;
            axAgent2.Characters[
"Role"].Balloon.FontSize = 11;
            axAgent2.Characters[
"Role"].Balloon.Style = 0x4160001;
            axAgent2.Characters[
"Role"].Speak("正在查询,请稍候",null);
            axAgent2.Characters[
"Role"].Listen(true);


下载示例应用程序:
http://files.cnblogs.com/lcybest/MSAgentSample.rar

posted on 2005-11-30 09:16 lcybest 阅读(589) 评论(2) 编辑 收藏

评论

#1楼 2005-12-30 14:15 BrianXue[未注册用户]  回复 引用   

goooood

#2楼 2006-09-13 22:44 jzknew@hotmail.com[未注册用户]  回复 引用   

收藏老