Path: news.graphite.sh!not-for-mail From: "Jake" Newsgroups: thirty4i.graphite.discuss Subject: OLEViewer to find COM Objects for scripting Date: Sun, 16 Jan 2000 13:20:44 -0600 Organization: thirty4 interactive Lines: 32 Message-ID: <85t9vc$jnl$1@thirty4.com> Reply-To: "Jake" NNTP-Posting-Host: user-33qs10b.dialup.mindspring.com X-Trace: thirty4.com 948054828 20213 199.174.4.11 (16 Jan 2000 20:33:48 GMT) X-Complaints-To: usenet@thirty4.com NNTP-Posting-Date: 16 Jan 2000 20:33:48 GMT X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.00.2615.200 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2615.200 Xref: news.graphite.sh thirty4i.graphite.discuss:97 While many folks may know about this, I thought a lot of you wouldn't and would find it very usefull. . . When I was trying to find out how to script an email interface, mian suggested I use the OLEViewer to find what COM objects I had installed on my machine. I had no idea what this tool was or how useful it is. You can use it to get a list of every COM object registered on your machine, and the ProgID that'll let you create a new instance of it for a script. As with the Agent example, if you want to create an instance of Microsoft Agent to use with your script, you'd use the following code in JScript: var obj = new ActiveXObject('Agent.Control.2'); "Agent.Control.2" is the name of COM object you want to create, and you can do the same thing for hundreds of objects on your computer, but finding out what those objects are can be tricky. That's where OLEViewer comes in. It'll list all the objects you have, give the ProdID (like Agent.Control.2) for the object, and what sort of properties/methods you can use with them. OLEViewer comes standard with Microsoft Visual Studio, but if you don't have that, it's available free from Microsoft at http://www.microsoft.com/com/resources/oleview.asp. If you're looking to do powerful things with WSH and graphite, I highly recommend getting this tool. Good luck, Jake