JScript .NET, Part VIII: Consuming IsPrime from ASP.NET - Doc JavaScript | WebReference

JScript .NET, Part VIII: Consuming IsPrime from ASP.NET - Doc JavaScript


JScript .NET, Part VIII: Consuming IsPrime from ASP.NET

In this column we continue our series on JScript .NET. In Part I, we laid down the groundwork for JScript .NET, showing you how to install IIS and the .NET SDK, and how to compile and run a JScript .NET program. In Part II, we showed you the major differences between JavaScript and JScript .NET. In Part III, we focused on JScript .NET's classes and their division among namespaces. In Part IV we taught you how to use inheritance in classes and interfaces. In Part V, we covered the third holy grail of object oriented programming: polymorphism. In Part VI, we showed you how to define Web services in JScript .NET and how to consume them from Internet Explorer. In Part VII, we showed you how to consume Web services from ASP.NET pages in general, and the add Web service in particular. In this column, we'll explain how to consume another specific Web service, the IsPrime Web service.

Web services are getting very popular. You can consume them from both clients and servers. We showed you in other columns (97, 98, 99, 105, and 106) how to consume them from clients. In Column 113 we showed you how to consume them from servers, using the add Web service. In this column, we'll show you how to use the IsPrime Web service from an ASP.NET page.

Please refer to Column 113 for a primer on ASP.NET. In this column, we'll focus on the IsPrime example. We'll show you in detail how to create the Web service's class, namespace, and .dll files. We'll show you how to write your ASP.NET file, including the script section to handle the button events. We'll demonstrate by GIFs how to use the ASP.NET page on your Web server.

In this column you will learn:

The following files were zipped for you: checkIsPrime.asmx (the IsPrime Web service) and isPrimeConsumer.aspx (a consumer of the IsPrime Web service).

Next: How to create a proxy


Produced by Yehuda Shiran and Tomer Shiran
All Rights Reserved. Legal Notices.
Created: July 15, 2002
Revised: July 15, 2002

URL: http://www.webreference.com/js/column114/index.html