The server object provides methods and properties that are accessed on the server. Most of the methods and properties are provided as functionality of the utility.
Grammar:
Server.property|method
Properties (property)
The Server object has only one property: The maximum time a scripttimeout program can run
Method (Methods)
CreateObject establishes an object instance.
Execute executes an ASP file
GetLastError returns an error code
HTMLEncode converts the specified HTML code.
MapPath converts a relative path to an absolute path.
Transfer sends all current status information to another ASP file
UrlEncode converts the specified code, including spaces, as a URL
Method details of the server object
CreateObject
Grammar
Server.CreateObject( progID )
Parameters
ProgID
Specifies the name of the component to be created, in the following format: [Vendor.] component[. Version].
Points:
In general, objects created by the Server.CreateObject method have a range of pages. This means that when this page's ASP program is finished, this object will automatically disappear.
To create an object that has a session or application range, you can use the Global.asa file in the
Execute
The Execute method calls an ASP file and executes it just as the ASP file for this call exists in this ASP file. This is much like a call to a class in many languages.
Grammar
Server.Execute( Path )
Parameters
Path
Specifies the path to the ASP file that is executed. If it is an absolute path, then it must be in the same place as the ASP application (directory).