⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 csdn_文档中心_microsoft agent技术应用.htm

📁 csdn10年中间经典帖子
💻 HTM
📖 第 1 页 / 共 2 页
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<!-- saved from url=(0051)http://www.csdn.net/develop/Read_Article.asp?id=310 -->
<!--内容开始//--><HTML><HEAD><TITLE>CSDN_文档中心_Microsoft Agent技术应用</TITLE>
<META content="MSHTML 5.00.3315.2870" name=GENERATOR>
<META content="text/html; charset=gb2312" http-equiv=Content-Type><LINK 
href="CSDN_文档中心_Microsoft Agent技术应用.files/csdn.css" rel=stylesheet></HEAD>
<BODY bgColor=#ffffff leftMargin=0 topMargin=0 marginheight="0" marginwidth="0">
<DIV align=center>
<STYLE>.title0 {
	COLOR: #ffffff; FONT-FAMILY: arial; FONT-SIZE: 17px; FONT-WEIGHT: bold; TEXT-DECORATION: none
}
A.title2:link {
	COLOR: #000000; TEXT-DECORATION: none
}
A.title2:visited {
	COLOR: #000000; TEXT-DECORATION: none
}
A.title2:active {
	COLOR: #ff0000; TEXT-DECORATION: none
}
A.title2:hover {
	COLOR: #ff0000; TEXT-DECORATION: none
}
</STYLE>

<SCRIPT language=JavaScript>
<!--
function submitlog(sign)
{
	var types=document.alogon.type.options[document.alogon.type.selectedIndex].value;				
	if (document.alogon.name.value!="" && document.alogon.pass.value!="")
	{
		if (types!="1")
			document.alogon.action="http://www.csdn.net/member/logon.asp";
		else
			document.alogon.action="http://expert.csdn.net/member/logon.asp";
		if(sign)
			document.alogon.submit();
		//return true;
	}
	else
	{
		if (document.alogon.name.value=="")
			alert("请输入用户名!");
		if (document.alogon.pass.value=="")
			alert("请输入密码");
		return false;
	}
	return true;
}
function GetMyPass()
{
	if (document.alogon.name.value!="")
	{
		document.alogon.action="http://www.csdn.net/member/getpass.asp";
		document.alogon.submit();
	}
	else
	{
		alert("请在姓名输入框里输入用户名或注册EMAIL!");
	}	
}
// -->
</SCRIPT>

<TABLE border=0 cellPadding=0 cellSpacing=0 width=770>
  <TBODY>
  <TR>
    <TD bgColor=#004d99 height=25 width=20></TD>
    <TD bgColor=#004d99>&nbsp;&nbsp; <A 
      href="http://www.csdn.net/member/login.asp"><FONT color=#ffff33>登 
      录..</FONT></A> &nbsp;&nbsp; <A href="http://www.csdn.net/member/zc.asp" 
      target=_blank><FONT color=#ffff33>[注 册]</FONT></A> &nbsp;&nbsp; <A 
      href="http://www.csdn.net/member/login.asp"><FONT 
      color=#ffff33>忘记密码</FONT> </A>&nbsp;&nbsp; <A 
      href="http://www.csdn.net/member/logonout.asp"><FONT 
      color=#ffff33>注销登录</FONT> </A></TD>
    <TD align=right bgColor=#990000 width=20><IMG height=25 
      src="CSDN_文档中心_Microsoft Agent技术应用.files/top_1.gif" width=20></TD>
    <FORM action=http://www.csdn.net/search_ok.asp method=post target=_blank>
    <TD align=right bgColor=#009999 width=250><FONT color=#ffffff><FONT 
      color=#ffffff><INPUT class=FormText_1 name=search size=15> <SELECT 
      class=FormText_1 name=type> <OPTION selected value=1>新闻标题</OPTION> 
        <OPTION value=2>软件名称</OPTION> <OPTION value=3>商品名称</OPTION> <OPTION 
        value=4>文档标题</OPTION> <OPTION value=6>职位名称</OPTION></SELECT> </FONT><INPUT class=td3 name=Submit type=submit value="搜 索">&nbsp; 
    </FONT></TD></FORM></TR></TBODY></TABLE>
<TABLE border=0 cellPadding=0 cellSpacing=0 width=770>
  <TBODY>
  <TR>
    <TD align=middle height=70 width=150><IMG height=60 
      src="CSDN_文档中心_Microsoft Agent技术应用.files/csdn.gif" width=120></TD>
    <TD align=middle width=470>
      <SCRIPT language=javascript>
	var rand = Math.random().toString(); 
	var ordval = parseInt(rand.substring(2,4)); 
	function Showad(width)
	{
		if(width=='468')
		{
				document.write("<a href='http://www.dearbook.com.cn/' target='_blank'><OBJECT classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' codebase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0' WIDTH=468 HEIGHT=60><PARAM NAME=movie VALUE='/adv//468x60.swf'> <PARAM NAME=quality VALUE=high> <EMBED src='/adv//468x60.swf' quality=high border=0 WIDTH=468 HEIGHT=60 TYPE='application/x-shockwave-flash' PLUGINSPAGE='http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash'></EMBED></OBJECT></a>");
				return;
		}
		if(width=='120')
		{
				document.write("<a href='http://www.csdn.net/csdn/csdnClick.aspx?ad=Oracle-button1&adurl&adurl=http://www.oracle.com/global/cn/documentation/10g/index.html?content.html' target='_blank'><img src='/adv/develop/grid_computing_120x60_text1.gif' width=120 HEIGHT=60 border=0></a>");
				return;
		}
		return;
	}
Showad('468')</SCRIPT>
    </TD>
    <TD align=middle width=150>
      <SCRIPT>Showad('120')</SCRIPT>
    </TD></TR></TBODY></TABLE>
<TABLE border=0 cellPadding=0 cellSpacing=0 width=770>
  <TBODY>
  <TR>
    <TD align=middle bgColor=#000000 colSpan=2 height=1 width=770></TD></TR>
  <TR>
    <TD align=middle bgColor=#004d99 height=28 width=150><FONT 
      class=title0>csdn.net</FONT></TD>
    <TD align=middle width=620>
      <SCRIPT src="CSDN_文档中心_Microsoft Agent技术应用.files/navigation1.js"></SCRIPT>
    </TD></TR>
  <TR>
    <TD align=middle bgColor=#000000 colSpan=2 height=1 
  width=770></TD></TR></TBODY></TABLE>
<TABLE border=0 cellPadding=0 cellSpacing=0 width=770>
  <TBODY>
  <TR>
    <TD bgColor=#f3f9fc height=23 width=10></TD>
    <TD bgColor=#f3f9fc>
      <MARQUEE onmouseout=this.start() onmouseover=this.stop() scrollAmount=5 
      scrollDelay=80>
      <SCRIPT src="CSDN_文档中心_Microsoft Agent技术应用.files/marquee.htm"></SCRIPT>
      </MARQUEE></TD>
    <TD align=right bgColor=#f3f9fc width=101>
      <SCRIPT>document.write("<img src=http://count.csdn.net/count/pageview1.asp?columnid=4&itemid=11 border=0 width=0 height=0>");</SCRIPT>
      <B>
      <SCRIPT language=JavaScript>
			<!--
			document.ns = navigator.appName == "Netscape"
			tmpDate = new Date();
			date = tmpDate.getDate();
			month= tmpDate.getMonth() + 1 ; 
			if(document.ns)
			{
				year1=tmpDate.getYear()
				year= year1.toString().substr(1,2);
			}
			else
				year= tmpDate.getYear();
			
			document.write(year);
			document.write(".");
			document.write(month);
			document.write(".");
			document.write(date);
			// -->
			</SCRIPT>
      </B>&nbsp;&nbsp;</TD></TR>
  <TR bgColor=#999999>
    <TD colSpan=3 height=1></TD></TR></TBODY></TABLE>
<TABLE border=0 width=770>
  <TBODY>
  <TR>
    <TD align=middle bgColor=#fafafa class=td1 vAlign=top width=150><BR>
      <SCRIPT src="CSDN_文档中心_Microsoft Agent技术应用.files/microsoft.js"></SCRIPT>
    </TD>
    <TD align=middle width=620>
      <TABLE bgColor=#eeeeee border=0 cellPadding=0 cellSpacing=0 width=600>
        <TBODY>
        <TR bgColor=#ffffff>
          <TD align=middle height=10 width=50></TD>
          <TD align=right><A href="http://www.csdn.net/">CSDN</A> - <A 
            href="http://www.csdn.net/develop/">文档中心</A> - <FONT 
            color=#003399>Visual C++</FONT>&nbsp;&nbsp;&nbsp;&nbsp; </TD></TR>
        <TR>
          <TD align=middle height=5></TD>
          <TD align=middle width=500></TD></TR>
        <TR>
          <TD align=middle bgColor=#003399 height=10><FONT 
            color=#ffffff>标题</FONT></TD>
          <TD><B>&nbsp;&nbsp;&nbsp;&nbsp;Microsoft 
            Agent技术应用</B>&nbsp;&nbsp;&nbsp;&nbsp;myhelper(原作) </TD></TR>
        <TR>
          <TD align=middle height=5></TD>
          <TD align=middle width=500></TD></TR>
        <TR>
          <TD align=middle bgColor=#003399><FONT color=#ffffff>关键字</FONT></TD>
          <TD width=500>&nbsp;&nbsp;&nbsp;&nbsp;Microsoft Agent技术应用</TD></TR>
        <TR>
          <TD align=middle height=5></TD>
          <TD align=middle width=500></TD></TR></TBODY></TABLE><!--文章说明信息结束//-->
      <TABLE border=0 width=600>
        <TBODY>
        <TR>
          <TD align=left><BR>Microsoft Agent技术应用<BR>&nbsp; &nbsp; &nbsp; 
            &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 
            &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 
            --AgentShell的实现原理介绍<BR><BR>[摘要]<BR>&nbsp; &nbsp; 
            本文介绍了如何应用Agent的以及AgentShell的实现原理和几个重要的技术处理。<BR><BR>[关键词]<BR>&nbsp; 
            &nbsp; Agent,COM,角色,语音识别,语音合成。<BR><BR>&nbsp; &nbsp; 
            对Agent编程的方法主要有使用VB,VC等语言进行ActiveX调用,除此之外还有直接通过VC进行COM<BR>编程调用。在VB中调用Agent是最简单不过了,但由于VB程序本身存在诸多缺陷,很难在实际中应用。<BR>而在VC中,由于Agent内部完全采用了UNICODE编码,同时还要处理各种繁杂的COM接口,从而也存在一<BR>定的问题。AgentShell是建立在Agent和应用程序之间的一个外壳程序,通过它可将Agent复杂的COM接<BR>口封装起来,转变为简单的函数调用,很好的实现对Agent的控制。同时AgentShell也作为一个独立的程<BR>序,可处理英文自动朗读等功能,本文将详细介绍其实现原理。<BR>&nbsp; 
            &nbsp; (一) 原理介绍<BR>&nbsp; &nbsp; AgentShell和Agent 
            Server的连接是通过COM调用来实现的,对于与应用程序的通信是通过WM_COPYDATA<BR>消息来实现的, 
            下图表示出AgentShell与其它程序的关系:<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 
            &nbsp; [ Agent Server ]<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 
            &nbsp; &nbsp; &nbsp; &nbsp; &brvbar;<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 
            &nbsp; &nbsp; [ COM调用 ]<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 
            &nbsp; &nbsp; &nbsp; &nbsp; &brvbar;<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 
            &nbsp; [ AgentShell ]<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 
            &nbsp; &nbsp; &nbsp; &nbsp; &brvbar;<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 
            &nbsp; &nbsp; &nbsp; [ 消息 ]<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 
            &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &brvbar;<BR>&nbsp; &nbsp; &nbsp; &nbsp; 
            &nbsp; &nbsp; [ 应用程序 ]<BR><BR>&nbsp; 
            将一个Agent控制加载相应的动画和语音码我们称之为“角色”,一般使用COM调用创建一个Agent角色,<BR>要经过以下几个过程:<BR>&nbsp; 
            &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; [ 初始化COM ] <BR>&nbsp; &nbsp; 
            &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &brvbar;<BR>&nbsp; 
            &nbsp; &nbsp; &nbsp; &nbsp; [ 连接Agent COM Sever,创建Agent控制 
            ]<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 
            &nbsp; &brvbar;<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; [ 
            注册Agent控制的消息反应器(Notify Sink) ]<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 
            &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &brvbar;<BR>&nbsp; &nbsp; &nbsp; &nbsp; 
            &nbsp; [ 加载角色数据文件,创建一个角色(Character) ]<BR>&nbsp; &nbsp; &nbsp; &nbsp; 
            &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &brvbar;<BR>&nbsp; &nbsp; &nbsp; 
            &nbsp; &nbsp; [ 设置角色的语言、初始位置以及其它属性 ]<BR>&nbsp; &nbsp; &nbsp; &nbsp; 
            &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &brvbar;<BR>&nbsp; &nbsp; &nbsp; 
            &nbsp; &nbsp; &nbsp; [ 显示角色 ]<BR><BR>&nbsp; 
            AgentShell中定义以下全局变量来控制角色的属性和动作:<BR>&nbsp; 角色的消息ID:&nbsp; &nbsp; long 
            g_lNotifySinkID。<BR>&nbsp; 角色ID: long g_lMyAgentID。<BR>&nbsp; 

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -