Quick References
      ADO
      ASP
      CSS2
      HTML
      JavaScript
      Jet SQL
      VBScript
      WML
      WMLScript
      WSH
      XHTML
      XML DOM
      XSLT

Features
      Knowledge Base
      Tutorials

Partners
     ZVON.ORG
     XML
     Planet Source Code
     VisualBuilder
     Web Design
     Your HTML Source
     XML/XSLT Forums
     ASPAlliance
     Scripts
     
     Programmers Heaven
     Tek-Tips Forums
     Developer Fusion
     Code Project











Property:  WshEnvironment.length

object.length

The length property is read only and returns a Long value which is the number of items in the collection.

The following VBScript code uses the length property to report the number of system environment variables currently defined.

Code:
Set objShell = WScript.CreateObject("WScript.Shell")
Set objSysEnv = objShell.Environment("SYSTEM")
WScript.Echo "There are", objSysEnv.length, "System environment variables."


Output:
There are 14 System environment variables.

 


Copyright 1999-2005 by Infinite Software Solutions, Inc. All rights reserved.
Trademark Information