Windows Scripting
  Home arrow Windows Scripting arrow Using .NET Interops in VBScript
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  
Silverlight  
Visual Basic.NET  
Windows Scripting  
Windows Security  
XML  
Mobile Linux 
App Generation ROI 
IBM® developerWorks 
ASP Web Hosting  
ASP.NET Web Hosting 
Windows Web Hosting
 
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

Using .NET Interops in VBScript
By: Nilpo
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 5 stars5 stars5 stars5 stars5 stars / 2
    2008-12-22

    Table of Contents:
  • Using .NET Interops in VBScript
  • Sorting Arrays in VBScript
  • Working with Strings
  • More with StringBuilder

  • 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


    Using .NET Interops in VBScript


    (Page 1 of 4 )

    Rumor has it that the .NET Framework is inaccessible from VBScript. It’s true that support for VBScript was never implied or included, and it's also true that VBScript cannot instantiate native .NET Framework classes. But that doesn’t mean that the .NET Framework is off limits for scripters—at least, not all of it.

    Have I gotten your attention yet?  I thought I saw a few ears perk up out there.

    Some of the .NET Interops do provide COM-scriptable interfaces, and probably more than you think!  You're not going to find a list of these anywhere; nor will they be marked this way in the MSDN documentation.  But with a little bit of trial and error you can discover them for yourself-well, at least the ones that I don't show you first.

    I'm not going to list and document each of these interops. Instead, I'm going to take a topical approach and let you see them in action, providing explanations as I go.  Keep in mind that this article is just the tip of the iceberg and is only meant to serve as an introduction to the concept of implementing .NET interops in VBScript.  There is much more available to you than you will see presented here.

    Finally, as you begin to explore these interops you will likely need to visit the MSDN documentation to examine the capabilities of each interop.  Although you may find one that can be instantiated in VBScript, it's important to remember that all of its members may not be exposed through a scripting interface.  You will likely need to perform some trial and error tests to get it working.

    More Windows Scripting Articles
    More By Nilpo


       · Thank you for these articles. I have been looking for a way to access the...
     

    WINDOWS SCRIPTING ARTICLES

    - More Windows Scripting Workarounds from Nilpo
    - Overloading Methods and More in VBScript
    - Improving MFC for Windows Vista
    - Regular Expressions in VBScript
    - Working with Dates in WMI
    - Completing Calendars with VBScript Date Func...
    - Building Calendars with VBScript Date Functi...
    - Working With Dates and Times in VBScript
    - Designing WCF DataContract Classes Using the...
    - Understanding Dates and Times in VBScript
    - Working With Arrays in VBScript
    - Compressed Folders in WSH
    - Using .NET Interops in VBScript
    - Nilpo`s Scripting Secrets, Vol I
    - Database operations using Silverlight 2.0 WC...





    © 2003-2009 by Developer Shed. All rights reserved. DS Cluster 3 Hosted by Hostway
    Stay green...Green IT