using System; using System.Collections; using System.ComponentModel; using System.Data; using System.Diagnostics; using System.Web; using System.Web.Services; namespace WebServerConvert { /// /// Summary description for MyService. /// [WebService(Namespace="http;//www.dur.ac.uk/barry.cornelius/webservices/", Description="This Web Service provides temperature conversion services.")] public class MyService : WebService { public MyService() { //CODEGEN: This call is required by the ASP.NET Web Services Designer InitializeComponent(); } #region Component Designer generated code /// /// Required method for Designer support - do not modify /// the contents of this method with the code editor. /// private void InitializeComponent() { } #endregion /// /// Clean up any resources being used. /// protected override void Dispose( bool disposing ) { } [WebMethod(Description="This converts from Centigrade to Fahrenheit.")] public double ToFahrenheit(double pCentigrade) { double tFahrenheit = 32 + pCentigrade*9/5; return tFahrenheit; } } }