Author Topic: Windows Web Services Functions  (Read 17406 times)

Support

  • Administrator
  • *****
  • Posts: 22
    • View Profile
Windows Web Services Functions
« on: June 26, 2014, 11:15:20 AM »
Hi Dave,

I don't mean to distract you from what you have going on but José Roca posted a link on his forum that looks interesting and something I might be able to try with your new COM interface for Script BASIC. Your thoughts?

John


dzzie

  • Guest
Re: Windows Web Services Functions
« Reply #1 on: June 26, 2014, 12:06:12 PM »
I have never played with web services api. That looks like a C++ api.

My basic take on web services, is its like DCOM (distributed com over network),
but instead of a binary RPC protocol, they are instead doing everything using
a web sever, HTTP, and putting the data into XML format as they shuttle it around.

So maybe a more readable form of DCOM extended to more implementations and
platforms, not just requiring complex MS technologies, but at the cost of bloating
the representation of the data way up, and shoe horn-ing it into an existing web
protocol.

The current COM code does not support DCOM. in vb CreateObject actually takes two
arguments, the second being an optional server name to contact that hosts the object.
I have never done any work with DCOM.

It looks like a web services api could be done just in a standard extension, no COM
required.

Support

  • Administrator
  • *****
  • Posts: 22
    • View Profile
Re: Windows Web Services Functions
« Reply #2 on: June 26, 2014, 12:32:02 PM »
I was just looking for something COM to play with.

I use cURL for all my web related tasks.

« Last Edit: June 26, 2014, 12:33:53 PM by support »

dzzie

  • Guest
Re: Windows Web Services Functions
« Reply #3 on: June 26, 2014, 12:43:02 PM »
I have never played with them, and havent tested them against the COM extension, but there are some cool system management things you can do with the WMI COM components such as listing all processes, getting installed AV software, scheduled tasks, services, system info etc.

http://msdn.microsoft.com/en-us/library/aa389763%28v=vs.85%29.aspx

Code: [Select]
Set objLocator = CreateObject("WbemScripting.SWbemLocator")
Set objService = objLocator.ConnectServer(".", "root\cimv2")
objService.Security_.ImpersonationLevel = 3
Set Jobs = _
    objService.ExecQuery("SELECT * FROM Win32_ScheduledJob")
i=0
For each Job in Jobs
    i = i+1   
    WScript.Echo Job.JobId & "  " _
        & Job.Command & VBNewLine
Next
If i = 0 Then
    WScript.Echo "No Jobs Scheduled with the AT command were found"
End If

Some other interesting COM objects from a systems management point of view:

http://www.robvanderwoude.com/vbstech_network_names_computer.php

Support

  • Administrator
  • *****
  • Posts: 22
    • View Profile
Re: Windows Web Services Functions
« Reply #4 on: June 26, 2014, 02:16:03 PM »
Thanks Dave for the links. It will give me something else to work on while getting the theming figured out.