Chapter 21. MyInfo Component
The MyInfo component allows you to maintain an encapsulated list of named string values that you use often throughout your site. This component was ostensibly designed (according to the documentation) for use with Personal Web Server (PWS), but it is also useful within Internet Information Server (IIS) ASP applications.
Each site can have only a single MyInfo component, and this component can contain as many values as you wish. This component helps you maintain this information by giving you a convenient, easy-to-use interface. Each value you store using the MyInfo object is stored in a text file on the web server. To access the value, you simply refer to the name of the object, followed by the dot operator, followed by the name of the value—exactly as if your value were another property of the MyInfo object.
Assuming your site has a single MyInfo object called
myinfoObj
defined with application-level
scope, you can retrieve any of its values (custom or not) using
simply the syntax ObjName.PropertyName
that you have used repeatedly. The example code at the end of this
chapter demonstrates this.
Get ASP in a Nutshell, 2nd Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.