Программирование в IIS




Пример 3.2


///

/// Summary description for Events.

///

public class Events : System.Web.Services.WebService

{

public Events()

{

//CODEGEN: This call is required by the

//ASP.NET Web Services Designer

InitializeComponent();

}

private System.Data.SqlClient.SqlConnection ServicesDBConn;

#region Component Designer generated code

//Required by the Web Services Designer

private IContainer components = null;

///

/// Required method for Designer support - do not modify

/// the contents of this method with the code editor.

///

private void InitializeComponent()

{

this.ServicesDBConn = new

System.Data.SqlClient.SqlConnection();

//

// ServicesDBConn

//

this.ServicesDBConn.ConnectionString =

"data source=amd1700;initial catalog=ASPNETServices;" +

"integrated security=SSPI;persist security info=False;" +

"workstation id=AMD1700;packet size=4096";

}

///

/// Clean up any resources being used.

///

protected override void Dispose( bool disposing )

{

if(disposing && components != null)

{

components.Dispose();

}

base.Dispose(disposing);

}

#endregion

}




Содержание  Назад  Вперед