IsURL Method

Back to Methods Reference

Validates a given URL.


VBA : RetVal = object.IsURL(URL)

VL : RetVal = (vla-IsURL object URL)

(vla-IsUrl util "")

  • Object : Utility
    The object or objects this method applies to.

  • LocalFile : String; input-only
    The URL to validate.

  • RetVal : Boolean
    TRUE: The string represents a valid URL.
    FALSE: The string is not a valid URL.


The definition of a "valid" URL is application-dependent, in that a given 3rd party application may not be interested in supporting all Internet protocols. For instance, an application that attempts to connect users to Web sites would probably not need to provide access to FTP sites. In this hypothetical application, a FALSE value would be returned if a URL that begins with something other than "http://" was entered.

The default functionality of this method for AutoCAD supports FTP, HTTP, HTTPS, and FILE protocols.

Example :

(defun c:al-isurl ()


(setq util (vla-get-utility 
(setq flag (vla-IsUrl util ""))

(princ flag)



The AutoLisp/Visual Lisp/VBA Resource Website
Search the WWW Search AfraLisp

Copyright 1999-Perpetuity by AfraLisp

All rights reserved.
Information in this document is subject to change without notice.
Site created and maintained by Kenny Ramage

The AutoLisp/Visual Lisp/VBA Resource Website