Chapter 18 -- Creating ActiveX Components with Visual Basic 6

Chapter 18

Creating ActiveX Components with Visual Basic 6.0

Introduction

In the last chapter, we saw the various types of architectures that can be designed using Microsoft Web technologies. We also took a look at the server objects provided with Microsoft Internet Information Server (IIS) 4.0 that developers for Microsoft Visual InterDev can take advantage of in their applications.

In this chapter, we'll see how we can create our own Microsoft ActiveX components, how they can be staged on the Web server, and how they can be called from within Active Server Pages (ASP) Web pages. We'll use Microsoft Visual Basic 6.0 to develop these ActiveX components.

This type of n-tier application architecture is often employed to create more reusable and component-based Web applications. It employs a browser-based client for the presentation layer, components in the middle tier for the business rules layer, and a relational database management system (RDBMS) for the data layer. Rather than having ASP communicate directly with the database via the Data Environment or the ActiveX Data Objects (ADO) model, the ASP Web pages call methods within COM components, which then communicate with the database. These COM components can also use ADO for their database access. ADO has a simpler object model than either Data Access Objects (DAO) or Remote Data Objects (RDO), some of the earlier database access techniques.

This application architecture is also a nice way to create more object-oriented and componentized code. Instead of having your business logic embedded within ASP Web pages (and often intermingled with the presentation logic), it resides in components. These components are compiled so that they can execute faster than interpreted ASP code.



Programming Microsoft Visual InterDev 6. 0
Programming Microsoft Visual InterDev 6.0
ISBN: 1572318147
EAN: 2147483647
Year: 2005
Pages: 143

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net