Windows Scripting
  Home arrow Windows Scripting arrow Page 2 - Overview Of The New Windows Scripting Host...
ASP Free Forums 
.NET  
ASP  
ASP Code  
ASP.NET  
ASP.NET Code  
BrainDump  
C#  
Code Examples  
Database  
Database Code  
IIS  
Microsoft Access  
MS SQL Server  
Visual Basic.NET  
Windows Scripting  
Windows Security  
XML  
ASP Web Hosting  
ASP.NET Web Hosting 
Dedicated Servers 
Moblin 
JMSL Numerical Library 
Windows Web Hosting
 
IBM® developerWorks 
Sun Developer Network 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
WINDOWS SCRIPTING

Overview Of The New Windows Scripting Host 5.6
By: Norbert Cartagena
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 4 stars4 stars4 stars4 stars4 stars / 21
    2003-09-22

    Table of Contents:
  • Overview Of The New Windows Scripting Host 5.6
  • Are You Ready?
  • Heeeeeeeere's Your Host.
  • New Contestants, Come On Down!
  • Let's Get This Show On The Road
  • Example Scripts
  • Roll The Credits

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    ADVERTISEMENT


    Overview Of The New Windows Scripting Host 5.6 - Are You Ready?


    (Page 2 of 7 )

    Ok, before we start, I'll presume that you know and understand what a script is. If you do, then skip to the next section. If you don't, then keep reading. A script is a set of instructions. The computer executes the instructions, then returns some sort of value: a number, string, list, or another data type. As far as the WSH goes, it might look something like this:


    < ?XML version="1.0" ? >
    <!-- 
    FilenameHello.wsf-->
     <
    job>
        <
    script language="VBScript" >
          
    WScript.Echo "Hello, from you VBScript friends! Please press OK."
        
    </script>
        <script language="JScript">
          WScript.Echo ("Hey, this is JScript. Can you click OK again? I can't quite reach it.") ;
        </script>
     </job>

    I say "might" because WSH is really a language-independent, object-model independent tool. At first, most of the stuff you'll be looking at will probably look like this:

    'This will tell you the Username, Domain, and Computer NameSet WshNetwork = Wscript.CreateObject("Wscript.Network")Wscript.echo WshNetwork.UsernameWscript.echo WshNetwork.UserDomainWscript.echo WshNetwork.ComputerName

    Just a tad different, wouldn't you agree?

    If you're sure that you have at least WSH 2.0 installed, then go ahead and copy and paste these into Notepad, saving them as example1.wsh and example2.vbs (respectively). Double click on them and see how they work. If you're not totally sure that you have at least version 2.0 installed, keep reading before you do anything else. Don't worry about whether you know those commands mean right now. By the time you finish this you'll know at least what they're doing and how. All you should care about right now is that you know what a script is. Hazzah!

    More Windows Scripting Articles
    More By Norbert Cartagena


     

    WINDOWS SCRIPTING ARTICLES

    - Adding Controls to an Application with WPF
    - A Portable Scripting Toolbox
    - WPF Through an Example: Introduction
    - Beginning SharePoint Web Part Development
    - More Alternative Languages for WSH
    - WPF Control Layout
    - WSH in Other Languages
    - Screen Capturing via GDI+ and GDI
    - Understanding Procedures in VBScript
    - Printing Documents in WSH
    - Generating Outlook Signatures Based on Activ...
    - VBScript: Converting and Formatting with Fun...
    - VBScript: Conversion and Format Functions
    - VBScript: Array Functions
    - VBScript: Strings, You Can`t Function withou...





    © 2003-2008 by Developer Shed. All rights reserved. DS Cluster 3 hosted by Hostway