导航

上海网站建设

专业的网站建设,上海网站建设中心,我们有最专业的团对与最优秀的网站设计人才,选择我们就是选择成功!

« 如何提高网站的PR值Sqlserver如何得到汉字的声母 »

SQLServer2005CE软件环境需求

DIV class=guanggao><SPAN id=contentAdv></SPAN></DIV>由于SQL Server 2005 Compact Edition和SQL Server 2005是同时代的产品,所以它们之间的互操作和结合性较之以前的SQL Server版本要好,为此如果要考虑使用SQL Server 2005 Compact Edition中的合并复制和远程数据访问技术进行数据同步的话,最好是使用SQL Server 2005作为后端的数据库。<BR><BR>  现在只要是能运行Visual Studio 2005的计算机都可以满足本专题具备的硬件要求(具体的软<a class="channel_keylink" href="http://www.itbulo.com/hardware/" target="_blank">硬件</a>要求大家可以查看SQL Server 2005 Compact Edition的联机丛书)。<BR><BR>  下面是笔者开发SQL Server 2005 Compact Edition程序所使用的软件环境:<BR><BR>  ·<a class="channel_keylink" href="http://edu.itbulo.com/sys/WinXp/" target="_blank">windows xp</a> SP2<BR>  ·Visual Studio 2005<BR>  ·Windows Mobile 6.0 Professional SDK <BR>  ·Microsoft ActiveSync 4.5<BR>  ·Internet Explorer 6.0<BR>  ·IIS<BR>  ·SQL Server 2005<BR><BR>  由于在本专题的前面部分,主要是介绍如何在Windows Mobile设备端通过ADO.NET对SQL Server 2005 Compact Edition进行操作,所以我们暂时不用考虑SQL Server 2005 Compact Edition与SQL Server 2005进行数据同步的问题。因此SQL Server 2005和IIS可以暂时不用安装,到使用到合并复制和远程数据访问技术时,笔者会详细介绍SQL Server 2005 Compact Edition和SQL Server 2005之间进行数据同步时需要的配置过程。<BR><BR>  <STRONG>智能设备开发环境的配置过程</STRONG><BR><BR>  现在就来介绍开发SQL Server 2005 Compact Edition移动设备端应用应具备的基本条件吧!通常我们都是使用Visual Studio 2005 Professional及更高的版本进行智能设备程序的开发(Visual Studio 2005 Express目前并不支持)。在安装Visual Studio 2005的过程中,只需要将图1中的“智能设备可编程技术”单选框选中,安装完毕后就可以利用Visual C#开发托管代码的智能设备程序了。<BR><BR>
<TABLE width="90%" align=center border=0>
<TBODY>
<TR>
<TD>
<DIV align=center><IMG style="BORDER-LEFT-COLOR: #000000; BORDER-BOTTOM-COLOR: #000000; BORDER-TOP-COLOR: #000000; BORDER-RIGHT-COLOR: #000000" src="http://edu.itbulo.com/UploadFiles_1485/200708/20070820174140970.jpg" border=1><BR>图1 选择“智能设备可编程技术” </DIV></TD></TR></TBODY></TABLE><BR>  我们在开发特定平台的智能设备程序时,往往需要事先安装相应的SDK(软件开发包)。比如说要开发针对Windows Mobile 6.0的应用程序,就要先安装Windows Mobile 6 SDK,否则Visual Studio 2005是不会出现Windows Mobile 6智能设备开发这个选项的。为此,我们在安装完Visual Studio 2005后,就需要安装ActiveSync软件,这样才能继续完成特定平台的SDK安装,这个先后次序希望大家一定要注意。<BR>ActiveSync可以同时支持PPC和微软智能手机(Smartphone),使用它可以很方便地在PC与PPC或智能手机间进行数据的同步。ActiveSync不仅可以同步文件,电子邮件及日程等,更有着许多额外的功能如同步SMS等。另外,Windows Mobile设备的用户还可以通过连接PC来访问<a class="channel_keylink" href="http://news.itbulo.com/net/" target="_blank">互联网</a>。ActiveSync可以说是PC与移动设备间的一座桥梁。<BR><BR>  现在最新的ActiveSync版本为4.5,该软件的中文版可以在该链接下载:http://download.microsoft.com/download/7/e/c/7ecbd388-7fb5-4e3e-b57f-12eaf7eb6136/setup.msi <BR><BR>  当ActiveSync安装完毕后,会提示你重新启动计算机才能完成相应的设置。ActiveSync的界面如图2所示:<BR><BR>
<TABLE width="90%" align=center border=0>
<TBODY>
<TR>
<TD>
<DIV align=center><IMG style="BORDER-LEFT-COLOR: #000000; BORDER-BOTTOM-COLOR: #000000; BORDER-TOP-COLOR: #000000; BORDER-RIGHT-COLOR: #000000" src="http://edu.itbulo.com/UploadFiles_1485/200708/20070820174146910.jpg" border=1><BR>图2 ActiveSync 4.5简体中文版</DIV></TD></TR></TBODY></TABLE><BR>  前文提到过,当我们需要开发特定平台的Windows Mobile应用程序时,需要安装相应的SDK。在本专题中将采用Windows Mobile 6.0作为开发的平台,因为Windows Mobile 6.0设备的ROM中已经内置了.Net Compact Framework 2.0 SP1和SQL Server 2005 Compact Edition,加上近几个月来中国市场上已经有越来越多的产品采用了Windows Mobile 6.0系统,相信不用多久Windows Mobile 6.0就会取代Windows Mobile 5.0,成为主流的<a class="channel_keylink" href="http://edu.itbulo.com/sys/" target="_blank">操作系统</a>。当然,在本专题中的所有程序也都可以在无需任何修改的条件下在Windows Mobile 5.0上运行。这是因为Windows Mobile 6.0和Windows Mobile 5.0都是基于Windows CE 5.0的,只不过Windows Mobile 6.0在原来5.0的基础上添加了一些新的特性,例如Vista风格等。<BR><BR>  Windows Mobile 6.0的SDK最新版可以包含两个版本,一个是针对Pocket PC和Pocket PC Phone Edition开发的Professional版本,另外一个则是针对Smartphone开发的Standard版本。在本专题中,我们主要是针对Pocket PC Phone Edition这种平台进行开发的,相对与Pocket PC它具备了通话的功能,而且<a class="channel_keylink" href="http://www.itbulo.com/hardware/" target="_blank">硬件</a>性能较之Smartphone有很大的提高,所以一般条件下安装Windows Mobile 6.0 Professional SDK即可。<BR><BR>  Windows Mobile 6.0 Professional SDK的下载地址如下:http://download.microsoft.com/download/f/2/3/f232f773-7edc-4300-be07-d3b76a5b3a91/Windows%20Mobile%206%20Professional%20SDK%20Refresh.msi<BR><BR>  Windows Mobile 6.0 Standard SDK的下载地址如下:<BR>http://download.microsoft.com/download/f/2/3/f232f773-7edc-4300-be07-d3b76a5b3a91/Windows%20Mobile%206%20Standard%20SDK%20Refresh.msi<BR><BR>  在Windows Mobile 6.0 Professional SDK安装完毕后,大家可以通过“开始”-“所有程序”-“Windows Mobile 6 SDK”-“Line of Business Extras”-“Mobile Line of Business Solution Accelerator”下载一个类似物流系统的移动行业解决方案,我将在本专题的最后部分对该项目进行详细的分析和讲解。该移动行业讲解方案的部分功能模块如3所示:<BR><BR>
<TABLE width="90%" align=center border=0>
<TBODY>
<TR>
<TD>
<DIV align=center><IMG style="BORDER-LEFT-COLOR: #000000; BORDER-BOTTOM-COLOR: #000000; BORDER-TOP-COLOR: #000000; BORDER-RIGHT-COLOR: #000000" src="http://edu.itbulo.com/UploadFiles_1485/200708/20070820174148904.jpg" border=1><BR>图3 “Mobile Line of Business Solution Accelerator”的登录模块和创建新订单模块</DIV></TD></TR></TBODY></TABLE><BR>  你也可以在该链接直接下载“Mobile Line of Business Solution Accelerator”的示例代码:http://download.microsoft.com/download/7/e/6/7e635836-bf36-436b-b8cc-0b16c74ba9b7/MobileLineofBusinessSolutionAccelerator.msi<BR><BR>  默认状态下,安装Windows Mobile 6.0 Professional SDK会自动安装Windows Mobile 6.0的英文设备仿真器,而中文的设备仿真器是需要我们单独下载的进行安装的,Windows Mobile 6.0中文仿真器如图4所示。<BR><BR>  Windows Mobile 6 Professional 中文镜像的下载地址:http://download.microsoft.com/download/0/1/2/012bfbba-9fe5-4e68-86c9-d434446d97dd/0804/Windows%20Mobile%206%20Professional%20Images%20(CHS).msi<BR><BR>  Windows Mobile 6 Standard中文镜像的下载地址:http://download.microsoft.com/download/0/1/2/012bfbba-9fe5-4e68-86c9-d434446d97dd/0804/Windows%20Mobile%206%20Standard%20Images%20(CHS).msi<BR><BR>
<TABLE width="90%" align=center border=0>
<TBODY>
<TR>
<TD>
<DIV align=center><IMG style="BORDER-LEFT-COLOR: #000000; BORDER-BOTTOM-COLOR: #000000; BORDER-TOP-COLOR: #000000; BORDER-RIGHT-COLOR: #000000" src="http://edu.itbulo.com/UploadFiles_1485/200708/20070820174152623.jpg" border=1><BR>图4 Windows Mobile 6中文仿真器的“今日”界面</DIV></TD></TR></TBODY></TABLE><BR>  当Windows Mobile 6.0 SDK安装完毕后,我们就可以通过Visual Studio 2005来开发针对Windows Mobile 6.0的智能设备程序了。如图5所示,在“智能设备”栏中我们会发现多了“Windows Mobile 6 Professional“这一项,而且通过右侧的模板,我们可以创建五种不同类型的项目。<BR><BR>
<TABLE width="90%" align=center border=0>
<TBODY>
<TR>
<TD>
<DIV align=center><IMG style="BORDER-LEFT-COLOR: #000000; BORDER-BOTTOM-COLOR: #000000; BORDER-TOP-COLOR: #000000; BORDER-RIGHT-COLOR: #000000" src="http://edu.itbulo.com/UploadFiles_1485/200708/20070820174154311.jpg" border=1><BR>图5 在Visual Studio 2005中创建Windows Mobile 6.0智能设备程序</DIV></TD></TR></TBODY></TABLE><BR>  接下来我们要安装的是SQL Server 2005 Compact Edition的SDK,该SDK包含用于在台式机上开发和部署应用程序的SQL Server 2005 Compact Edition 运行时(必须安装),而且对于不同类型<a class="channel_keylink" href="http://www.itbulo.com/hardware/cpu/" target="_blank">处理器</a>的移动设备,其对应的SQL Server 2005 Compact Edition组件安装包也是不同的。除此之外,SDK中还包含了的SQL Server 2005 Compact Edition的帮助文档,这大概是当前学习SQL Server 2005 Compact Edition的唯一权威资料了。<BR><BR>  在笔者当前写作的阶段,SQL Server 2005 Compact Edition SDK的下载页面依然是无法打开的,这种状况大概已经持续了半年左右。下面我将给出SQL Server 2005 Compact Edition SDK直接下载地址:<BR><BR>  SQL Server 2005 Compact Edition SDK中文:http://download.microsoft.com/download/0/9/4/094d27fe-8d7f-4b0b-8130-555ed2c8b366/SSCE31SDK-CHS.msi<BR><BR>  SQL Server 2005 Compact Edition SDK英文:http://download.microsoft.com/download/e/5/b/e5b19eb6-4141-4dba-a1fb-e95693c1538f/SSCE31SDK-ENU.msi<BR><BR>  SQL Server 2005 Compact Edition SDK安装完毕后,就可以在其安装目录的“\v3.1\SDK\bin\Desktop”子文件夹中找到一个名为“SQLServerCE31-zh-CHS.msi”的文件,该文件就是用于在台式机上开发和部署应用程序的SQL Server 2005 Compact Edition 运行时。因为使用到SQL Server 2005 Compact Edition的智能设备托管程序需要引用“System.Data.SqlServerCe”命名空间,而该命名空间又是由“System.Data.SqlServerCe.resources.dll “文件提供的,为此必须在计算机上安装SQL Server 2005 Compact Edition 运行时。<BR><BR>  “v3.1\SDK\Docs\zh-CHS”子文件夹中的“SSCE31BOL-CHS.msi”文件就是SQL Server 2005 Compact Edition帮助文档,因为其内容非常详细,因此建议安装。在“\v3.1\SDK\bin\wce500”子文件夹中,包含了针对不同类型<a class="channel_keylink" href="http://www.itbulo.com/hardware/cpu/" target="_blank">处理器</a>的SQL Server 2005 Compact Edition组件安装包,如图6所示。至于如何将SQL Server 2005 Compact Edition的各个组件安装到移动设备上,将在下一小节详细介绍。<BR><BR>
<TABLE width="90%" align=center border=0>
<TBODY>
<TR>
<TD>
<DIV align=center><IMG style="BORDER-LEFT-COLOR: #000000; BORDER-BOTTOM-COLOR: #000000; BORDER-TOP-COLOR: #000000; BORDER-RIGHT-COLOR: #000000" src="http://edu.itbulo.com/UploadFiles_1485/200708/20070820174158194.jpg" border=1><BR>图6 针对7种不同<a class="channel_keylink" href="http://www.itbulo.com/hardware/cpu/" target="_blank">处理器</a>的SQL Server 2005 Compact Edition组件安装包</DIV></TD></TR></TBODY></TABLE><script language='javascript' src='http://www.iTbulo.com/gg/200703/79.js'></script></td>
</tr>
</table><!--c-pip文章正文中间240*200--><SPAN id=span_ad3>
<SCRIPT language=JavaScript>
document.write("<script src=\"http://www.iTbulo.com/gg/200703/78.js\"><\/script>");</SCRIPT>
</SPAN>
<SCRIPT>
document.getElementById("contentAdv").innerHTML=document.getElementById("span_ad3").innerHTML;
document.getElementById("span_ad3").innerHTML="";
</SCRIPT>
</td>
<td width="1" valign="top" bgcolor="#A8A8A8"></td>
<td width="173" valign="top" bgcolor="F3F3F3">
<table width="100%" border="0" cellspacing="0" cellpadding="0" align="center">
<tr>
<td height="21" align="center" valign="middle" bgcolor="DFDFDF"><strong>文章搜索</strong></td>
</tr>
<tr>
<td height="2" bgcolor="A3A3A3"></td>
</tr>
<form method="Get" name="SearchForm" action="/Search.asp" target="_blank"><TR>
<TD height="40" align=center><input name="Field" type="hidden" id="Field" value="Title"><INPUT name=Keyword id="Keyword" size=16> <INPUT type=submit value=搜索 name=submit onClick="if(this.form.Keyword.value=='') {alert('请输入关键字');return false;}"></TD></TR></FORM>
<tr>
<td height="21" align="center" valign="middle" bgcolor="DFDFDF"><strong>

发表评论:

◎欢迎参与讨论,请在这里发表您的看法、交流您的观点。

Powered By Z-Blog .Templete from Google黑板报

Copyright 上海网站建设 www.shwebc.com. Some Rights Reserved.