MOSS 2010:Visual Studio 2010开发体验(19)——ECMAScript Object Model(四)

然后,我们添加一个Application Page

MOSS 2010:Visual Studio 2010开发体验(19)——ECMAScript Object Model

 

MOSS 2010:Visual Studio 2010开发体验(19)——ECMAScript Object Model

 

  接下来,添加SP.js的引用,并且对其他几个区域做一些初始化工作

<%@ Assembly Name="$SharePoint.Project.AssemblyFullName$" %> 
<%@ Import Namespace="Microsoft.SharePoint.ApplicationPages" %> 
<%@ Register Tagprefix="SharePoint" Namespace="Microsoft.SharePoint.WebControls" Assembly="Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %> 
<%@ Register Tagprefix="UtilitIEs" Namespace="Microsoft.SharePoint.Utilities" Assembly="Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %> 
<%@ Register Tagprefix="asp" Namespace="System.Web.UI" Assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" %> 
<%@ Import Namespace="Microsoft.SharePoint" %> 
<%@ Assembly Name="Microsoft.Web.CommandUI, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %> 
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="MyClientOMPage.aspx.cs" Inherits="SharePointProject1.Layouts.SharePointProject1.MyClientOMPage" DynamicMasterPageFile="~masterurl/default.master" %> 
 
<asp:Content ID="PageHead" ContentPlaceHolderID="PlaceHolderAdditionalPageHead" runat="server"> 
  <SharePoint:ScriptLink Name="SP.JS" runat="server" OnDemand="true" Localizable="false"></SharePoint:ScriptLink> 
</asp:Content> 
 
<asp:Content ID="Main" ContentPlaceHolderID="PlaceHolderMain" runat="server"> 
<SharePoint:FormDigest ID="FormDigest1" runat="server" /><!-如果需要修改数据的话,则需要添加这个,以便做身份信息的校验--> 
 
<!--下面这个表格将用来填充员工数据--> 
 
  <table id=”employees” width="100%" border="1"> 
    <thead> 
      <tr> 
        <td>FirstName</td> 
        <td>LastName</td> 
      </tr> 
    </thead> 
    <tbody> 
      <tr id="template"> 
        <td></td> 
        <td></td> 
      </tr> 
    </tbody> 
  </table> 
 
</asp:Content> 
 
<asp:Content ID="PageTitle" ContentPlaceHolderID="PlaceHolderPageTitle" runat="server"> 
ECMAScript 客户端对象模型演示页面 
</asp:Content> 
 
<asp:Content ID="PageTitleInTitleArea" ContentPlaceHolderID="PlaceHolderPageTitleInTitleArea" runat="server" > 
Employee List 
</asp:Content> 

posted @ 2012-03-17 22:38  江南轻舞飞扬  阅读(139)  评论(0编辑  收藏  举报