All pastes #243401 Raw Edit

Someone

public text v1 · immutable
·published 2006-11-08 12:38 UTC
rendered paste body
using System;
using System.Data;
using System.Configuration;
using System.Collections.Generic;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;

public partial class EventLogView : System.Web.UI.Page
{
    private DataAccess data;
    private config configuration;
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack)
        {
            configuration = new config();
            data = new DataAccess(configuration.ConnectionString);
            List<string> computers = data.Get_Computers();
            DropDownList_Computer.DataSource = computers;
            DropDownList_Computer.DataBind();
        }
        else {
            if (DropDownList_Computer.SelectedValue != null) {
                List<string> lognames = data.Get_Lognames(DropDownList_Computer.SelectedValue);
                DropDownList_Logname.DataSource = lognames;
                DropDownList_Logname.DataBind();
            }
        }
    }
}