The IDLnetURL::Delete procedure method deletes a file on an HTTP server.

If the URL keyword is not set, the URL_PATH property must be set to the destination (filename) on the remote HTTP server.


This method generates an error if the delete fails. The method sets the RESPONSE_CODE and RESPONSE_HEADER properties, which contain response information sent by the remote server. The information stored in these properties can be useful when troubleshooting transmission problems.

Use a CATCH statement to trap errors and print the error message and response code. An HTTP server 401 response code means that a login is required, or the current username and password are incorrect.

Remote servers typically must be configured to support HTTP Delete operations. If the remote server does not support these operations, the HTTP Delete will fail. Typical error responses to this situation are “400 Bad Request” and “405 Method Not Allowed”.


Obj->[IDLnetURL::] Delete [, URL=string]





Set this keyword equal to a string that specifies the complete URL of the file to be deleted. If this keyword is set, the URL_* properties are ignored.

Note: When using a URL that contains a password, the password appears as clear text. To avoid this security problem when using a password, set the URL_* properties explicitly rather than using the URL keyword.

Version History



See Also

IDLnetURL::Get, IDLnetURL::Put