VS2008里开发WAP的模版已经装了 求一个开发实例(包含如何连接数据库,显示数据,控件的运用)
分不多 求大大们指教下 ORZ

解决方案 »

  1.   

    <% Response.ContentType ="text/vnd.wap.wml"%>
    < xml version="1.0" encoding="gb2312" >
    <!DOCTYPE wml PUBLIC "-//OPENWAVE.COM//DTD WML 1.3//EN" "http://www.openwave.com/dtd/wml13.dtd">
    <wml>
    <card title="Wap-Asp例子">
    <p align="center"><img src="test.png" alt=""/></p>
    <p> 
    <%
    Response.Write("welcome")
    %>
    <br/>
    <a href="http:// wap.uni-wise.com " title="确定">返回上级</a><br/>
    </p>
    <do type="options" label="回首页">
    <go href="http://wap.uni-wise.com"/>
    </do>
    </card>
    </wml>1.3.2. Asp.Net<%@ Page language="c#" Codebehind="WebForm1.aspx.cs" AutoEventWireup="false" Inherits="Test_Wap.WebForm1" ContentType="text/vnd.wap.wml"%>
    < xml version="1.0" encoding="gb2312" >
    <!DOCTYPE wml PUBLIC "-//OPENWAVE.COM//DTD WML 1.3//EN" "http://www.openwave.com/dtd/wml13.dtd">
    <wml>
    <card title="<%=name%>">
    <p align="center" mode="nowrap">
    <%
    Display();
    %>
    </p> 
    <do type="options" label="回首页">
    <go href="http://wap.uni-wise.com"/>
    </do>
    </card>
    </wml>1.3.3. WebForm1.aspx.cs文件using System;
    using System.Collections;
    using System.ComponentModel;
    using System.Data;
    using System.Drawing;
    using System.Web;
    using System.Web.SessionState;
    using System.Web.UI;
    using System.Web.UI.WebControls;
    using System.Web.UI.HtmlControls;
    namespace Test_Wap
    {
    /// <summary>
    /// WebForm1 的摘要说明。
    /// </summary>
    public class WebForm1 : System.Web.UI.Page
    {
    protected string name="Wap-Asp.Net例子";
    private void Page_Load(object sender, System.EventArgs e)
    {
    // 在此处放置用户代码以初始化页面
    }
    protected void Display()
    {
    Response.Write("Welcome");
    }
    #region Web 窗体设计器生成的代码
    override protected void OnInit(EventArgs e)
    {
    //
    // CODEGEN: 该调用是 ASP.NET Web 窗体设计器所必需的。
    //
    InitializeComponent();
    base.OnInit(e);
    }/// <summary>
    /// 设计器支持所需的方法 - 不要使用代码编辑器修改
    /// 此方法的内容。
    /// </summary>
    private void InitializeComponent()

    this.Load += new System.EventHandler(this.Page_Load);
    }
    #endregion
    }
    }
    Wap上的业务,图铃下载类占了大部分,而且这两种业务的收入也占中国联通和中国移动Wap总收入80%还多
      

  2.   

     <mobile:Label ID ="lblname" Runat="server" BreakAfter="True"><%#Eval("name") %></mobile:Label>谢谢2L  但是我不是用XML做的(不熟=。=、) 如果以<mobile:....></mobile:...>形式开发 应该怎么做