Hello world!

欢迎使用 WordPress。这是您的第一篇日志。您可以编辑它或是删除它,然后开始写您自己的博客。

Posted in 未分类 | 1 Comment

Silverlight 视频教程

比较系统的Silverlight 实例视频教程
http://www.zhenjiandan.com/SerialPage_46.html

Posted in 未分类 | Tagged | Leave a comment

最近作品

最近制作了一个 视频教程的网站 望弟兄们帮我踩踩!

网址: www.zhenjiandan.com

Posted in 未分类 | Leave a comment

秋思

作者:江波


孤叶枝头叹秋寒


斜阳清风寄相思


往事如酒醉孤影


愿守此情度余生

最后一片红叶

Posted in 未分类 | Leave a comment

江波词

魔兽争霸---剑圣篇

半生殊荣逐庸逝,
何必把酒醉当歌。
他日必踏失足处,
利刃再舞定乾坤。

Posted in 未分类 | Tagged | 2 Comments

Mobile ObjectList 多列显示

前台程序
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="StationThumbnailReport.aspx.cs" Inherits="HomePage.StationThumbnailReport" %>
<%@ Register TagPrefix="mobile" Namespace="System.Web.UI.MobileControls" Assembly="System.Web.Mobile" %>


<html xmlns="http://www.w3.org/1999/xhtml" >
<body>
<mobile:Form ID="form1" Runat="server">
        <mobile:ObjectList ID="olTable" Runat="server" AutoGenerateFields="False" CommandStyle-StyleReference="subcommand" LabelStyle-StyleReference="title" OnItemCommand="olTable_ItemCommand" TableFields="Name;State;SubTotal" DefaultCommand="View" >
            <Command Name="View" Text="查看" />
            <Field Name="Name" DataField="Name" Title="桌台" />
            <Field Name="State" DataField="Text_State"  Title="状态" />
            <Field Name="SubTotal" DataField="Text_SubTotal"  Title="小计" />
            <Field Name="TableId" DataField="Id" Title="桌台号" Visible="False" />
        </mobile:ObjectList>
        <mobile:Label ID="lblSummary" Runat="server" />
    </mobile:Form>
</body>
</html>


后台程序

    public partial class StationThumbnailReport : System.Web.UI.MobileControls.MobilePage
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                DataBind();
            }
        }


        public override void DataBind()
        {
            //base.DataBind();
            Station stationInstance = DBProvider.GetActiveStations(RightHandler.CurConsumerId).Find(p => p.AId == CurStationId);


            if (stationInstance != null)
            {
                CustomBinding binding = new CustomBinding();
                binding.Elements.Add(new TextMessageEncodingBindingElement(MessageVersion.Soap11, Encoding.UTF 8) );
                binding.Elements.Add(new HttpTransportBindingElement());


                string remoteAddress = "http://" + stationInstance.Ip + ":" + stationInstance.Port.ToString() + "/WAPRemoteService";


                EndpointAddress endpoint = new EndpointAddress(remoteAddress);


                WAPRemoteServiceClient serviceProxy = new WAPRemoteServiceClient(binding, endpoint);


                StationThumbnailReportStore reportStore = serviceProxy.GetStationThumbnailReportStore();
                lblSummary.Text = string.Format("桌台总数:{0} 人数:{1} 空闲:{2} 预定:{3} 使用:{4} 金额:{5}" ,
                    reportStore.TableCount, reportStore.PeopleCount, reportStore.FreeCount, reportStore.ReserveCount, reportStore.UsingCount, reportStore.MoneyAmount);

                olTable.DataSource = reportStore.Tables;
                olTable.DataBind();
            }
        }



        protected void olTable_ItemCommand(object sender, ObjectListCommandEventArgs e)
        {
            if (e.CommandName == "View")
            {
                Server.Transfer(string.Format("StationTableReport.aspx?StationId={0}&TableId={1}", CurStationId, e.ListItem["TableId"]));
            }
        }


        public int CurStationId
        {
            get
            {
                int iCurStationId = UnAssignedId;
                string txtStationId = Request.Params["StationId"];
                if (txtStationId != null && txtStationId.Trim() != "")
                {
                    iCurStationId = int.Parse(txtStationId);
                }


                return iCurStationId;
            }
        }


        protected const int UnAssignedId = -1;
    }

Posted in 程序技巧 | Tagged | 1 Comment

近期作品

Posted in 未分类 | Leave a comment

AssignFile 操作串口

AssignFile(F,'COM1: 9600, N, 8, 2, ASC');

Posted in 未分类 | Tagged | Leave a comment

编译器错误信息: cs0016: 未能写入输出文件


错误信息:
编译器错误信息:   cs0016:   未能写入输出文件“c:windowsmicrosoft.netframeworkv1.1.4322temporary   asp.net   filesshopping   cart_shopping257ab4203f5c7b3blg70ccd.dll”--“拒绝访问。

解决步骤:

    1.禁用或设置 Indexing Service 服务
    2.检查 Bin 目录的访问权限
    3.设置 Temporary ASP.NET Files 目录的访问权限
    4.设置 WindowsTemp 的权限

给Network service添加FULL CONTROL权限。即:设置 Temporary ASP.NET Files 目录和WindowsTemp 访问用户为aspnet和Network service,权限为FULL CONTROL

Posted in 未分类 | Leave a comment

解决showModelessDialog()页面中postback 打开新页面的问题;

解决showModelessDialog()页面中postback 打开新页面的问题;
<head>
<base target="_self">
</head>

Posted in 未分类 | Leave a comment