please dont rip this site

ASPTear Component

Component Properties

The following table describes which properties are supported by the AspTear component. Property names are in Italic. Get means that the property value can be read, set means that it can be changed. Default values are also described.





get/set - default: "text/*"

Defines the HTTP_ACCEPT header. By default, only text documents are handled by this component. (*)


get/set - default: 2000

You can set a connection timeout for connecting to remote web servers. This property is defined in milliseconds.


get/set - default: "application/x-www-form-urlencoded"

Best to leave to the default - this default content type is needed to successfully GET and POST to ASP pages.


get/set - default: True

Specify whether the component should automatically follow redirects (302's)


get/set - default: False

Use to prevent local caching from WinInet (component will always roundtrip to server)


get only - returns headers after retrieve operation

Retrieve the headers after the retrieval of the document.


get/set - default: "HTTP/1.0"

Determine the version of HTTP that should be used to connect to the remote Web server.


get/set - default: False

Allows you to ignore invalid certificate expiration dates - for example, certificates that have already expired would cause the page not to download.


get/set - default: False

Allows you to ignore invalid common names in certificates. For example, the certificate was issued for, but is used for - then the CN is invalid.


get/set - default: not set, autodetermine

Set port number manually. Preferred way is by appending to URL, like


get/set - default: "" (no proxy)

Enter the proxy server you want to use for accessing the Internet. The full URL including protocol and port must be supplied, eg:


get/set - default: "" (no username)

Use for proxies that require authentication other than Windows integrated (MS Proxy or ISA).


get/set - default: "" (no password)

Use for proxies that require authentication other than Windows integrated (MS Proxy or ISA).



When using FollowRedirects=False, you can determine the redirect target using this property.


get/set - default: none

You can set the referrer if the page you are calling needs one.


get/set - default: False

Set to True when you want to send a client certificate when connecting to an SSL secured Web site. Please see the section entitled Client Certificates for more information.


get/set - default: False

If you don't have control over the machine where IIS is running on, the IIS certificate authority store cannot be updated using the iisca utility. In that case, you can tell the component to simply trust any CA it comes across. (**)



Default: "Mozilla/4.0 (compatible; MSIE 5.5; Windows NT 5.0; AspTear 1.5)"

If you need to set a specific user agent (eg, you want to retrieve a page that does a browser check and acts accordingly), simply change the personality of the component.


(*) In the current release, you can set only one Accept type. If you want to receive any content, simply use "*/*" as Accept type.

(**) The iisca utility can be found in the WINNT\system32\inetsrv directory. It allows you to copy root certificates from the user's root store to IIS's root store. This must be done for every new CA you want to trust.


Component Methods

The following methods are supported by the AspTear component:




AddCookie(CookieName, CookieValue)

Add a cookie to the page request. Cookies must be added before either calling Retrieve or Save.

AddHeader(Headername, Headervalue)

Add an additional header to the request. Headers must be added before either calling Retrieve or Save. Note that the COOKIE header can be modified only via the AddCookie method.


Resets all component properties to their default values. Use it when retrieving multiple files in a row with different parameters.

Retrieve(URL, Method, Payload, Username, Password)

Payload is the Querystring or POST data. It is formatted as follows: variable=Server.UrlEncode(data)&…

If Username and Password are not needed, supply an empty string.

Method is an integer, with POST being represented by 1, GET with 2, and HEAD with 3.

Save(URL, Method, Payload, Filename, Username, Password)

Parameters are the same as for Retrieve. Filename, however, must be supplied with Server.MapPath already applied (component does not rely on OnStartPage event from IIS, thus being usable from all Automation environments)


file: /Techref/language/asp/comp/asptear/index.htm, 32KB, , updated: 2005/7/26 12:51, local time: 2024/6/24 13:21, owner: JMN-EFP-786,

 ©2024 These pages are served without commercial sponsorship. (No popup ads, etc...).Bandwidth abuse increases hosting cost forcing sponsorship or shutdown. This server aggressively defends against automated copying for any reason including offline viewing, duplication, etc... Please respect this requirement and DO NOT RIP THIS SITE. Questions?
Please DO link to this page! Digg it! / MAKE!

<A HREF=""> ASPTear</A>

After you find an appropriate page, you are invited to your to this massmind site! (posts will be visible only to you before review) Just type a nice message (short messages are blocked as spam) in the box and press the Post button. (HTML welcomed, but not the <A tag: Instead, use the link box to link to another page. A tutorial is available Members can login to post directly, become page editors, and be credited for their posts.

Link? Put it here: 
if you want a response, please enter your email address: 
Attn spammers: All posts are reviewed before being made visible to anyone other than the poster.
Did you find what you needed?


Welcome to!


Welcome to!