资源简介

本网站采用CSS+DIV和javascript设计前台页面,采用C#语言编写后台代码,以Microsoft SQL Server 2005作为后台数据库,选用ADO.NET访问数据库来实现各种功能 网站登录用户名:mary 登录密码:016 本程序为本人课设 可以完美运行 希望大家多多回复多多评论 好的资源需要共享

资源截图

代码片段和文件信息

using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.xml.Linq;
using System.Data.SqlClient;

public partial class bingrenxinxi : System.Web.UI.Page
{
    protected void Page_Load(object sender EventArgs e)
    {
        SqlConnection conn = new SqlConnection();
        conn.ConnectionString = “Data Source=www-7bffdfc560a;Initial Catalog=hospital;User ID=sa;Password=206“;
        conn.Open();
        /*
         执行
        SqlCommand cmd = new SqlCommand();
        cmd.CommandText = “select *from 病人“;
        cmd.Connection = conn;
         * 
         * 
         * 
        SqlDataReader data;
        data = cmd.ExecuteReader();
         */
        SqlCommand cmd = new SqlCommand();
        cmd.CommandText = “select *from 病人“;
        cmd.Connection = conn;
        SqlDataReader data;
        data = cmd.ExecuteReader();

        GridView2.DataSource = data;
        GridView2.DataBind();

        /*
        Response.Write(““);
        Response.Write(““);
        Response.Write(““);
        Response.Write(““);
        Response.Write(““);
        Response.Write(““);
        Response.Write(““);
        Response.Write(““);

        while (data.Read())
        {
            Response.Write(““);
            Response.Write(““);
            Response.Write(““);
            Response.Write(““);
            Response.Write(““);
            Response.Write(““);
            Response.Write(““);
        }
        Response.Write(“
“);
        Response.Write(“病人挂号编号“);
        Response.Write(“
“);
        Response.Write(“年龄“);
        Response.Write(“
“);
        Response.Write(“病人姓名“);
        Response.Write(“
“);
        Response.Write(“性别“);
        Response.Write(“
“);
        Response.Write(“地址“);
        Response.Write(“
“);
        Response.Write(“联系电话“);
        Response.Write(“
“);
            Response.Write(data.GetValue(1).ToString());
            Response.Write(“
“);
            Response.Write(data.GetValue(0).ToString());
            Response.Write(“
“);
            Response.Write(data.GetValue(2).ToString());
            Response.Write(“
“);
            Response.Write(data.GetValue(3).ToString());
            Response.Write(“
“);
            Response.Write(data.GetValue(4).ToString());
            Response.Write(“
“);
            Response.Write(data.GetValue(5).ToString());
            Response.Write(“
“);////此句若注释掉 则在网页中生成的表在按钮下方 。不注释则浮动在最左上方
*/
      
        conn.Close();
        conn.Dispose();
    }

    protected void GridView2_SelectedIndexChanged(object sender EventArgs e)
    {

    }
    protecte

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2011-01-19 18:54  程序\
     目录           0  2011-01-19 18:54  程序\App_Data\
     文件    10485760  2011-01-06 23:17  程序\App_Data\ASPNETDB.MDF
     文件      516096  2011-01-06 23:17  程序\App_Data\aspnetdb_log.ldf
     文件        5287  2011-01-09 09:54  程序\bingrenxinxi.aspx
     文件       11759  2011-01-08 23:15  程序\bingrenxinxi.aspx.cs
     文件       15221  2011-01-09 10:49  程序\Default.aspx
     文件        6841  2011-01-09 10:48  程序\Default.aspx.cs
     目录           0  2011-01-26 10:01  程序\images\
     文件       13371  2011-01-08 09:17  程序\images\1.jpg
     文件       22582  2011-01-08 09:18  程序\images\2.jpg
     文件       16492  2011-01-08 09:37  程序\images\3.jpg
     文件       18189  2011-01-08 09:20  程序\images\4.jpg
     文件       15929  2011-01-08 09:26  程序\images\5.jpg
     文件       18141  2011-01-08 09:18  程序\images\6.jpg
     文件       12583  2011-01-08 09:19  程序\images\7.jpg
     文件          61  2006-10-12 12:16  程序\images\arrow.gif
     文件         897  2006-10-12 12:35  程序\images\bar.gif
     文件         800  2006-10-12 12:44  程序\images\baractive.gif
     文件         155  2006-05-24 11:40  程序\images\barul.gif
     文件          91  2006-10-12 11:17  程序\images\bg.gif
     文件        1963  2011-01-07 10:47  程序\images\bk.jpg
     文件         101  2006-10-12 14:15  程序\images\h3bg.gif
     文件       22310  2011-01-07 10:39  程序\images\intro.jpg
     文件          47  2006-10-12 12:25  程序\images\leftintrobg.gif
     文件      357734  2010-05-14 21:12  程序\images\logo.bmp
     文件       11426  2006-10-14 11:27  程序\images\package.gif
     文件        4275  2011-01-08 23:39  程序\keshi.aspx
     文件        6459  2011-01-08 23:15  程序\keshi.aspx.cs
     文件        1246  2011-01-08 11:24  程序\login.aspx
     文件         926  2011-01-08 10:09  程序\login.aspx.cs
............此处省略6个文件信息

评论

共有 条评论