Rank: Newbie Groups: Member
Joined: 10/30/2009 Posts: 2 Location: Christchurch, New Zealand
|
Hi, We are using 2008 Terminal Server to run Outlook. My VBA code runs in Outlook and tries to create an object referring to SScripting.IPNetwork. The code fails. The same code works perfectly in a 32 bit environment.
As a test, I've registered sscrrun.dll in c:\windows\sysWow64 and can run the test script below if I use the 32 bit version of cscript in sysWow64 but get the following error message if I use cscript from system32. I believe this is because the vesion in system32 is actually the 64 bit version (http://social.msdn.microsoft.com/Forums/en-US/windowsgeneraldevelopmentissues/thread/7da87be4-8fc9-4962-8354-52e852c9c0bc)
when run using csript from system32: C:\temp\TestSyslog.vbs(7, 1) Microsoft VBScript runtime error: ActiveX componen t can't create object: 'SScripting.IPNetwork'
TestSyslog.vbs is
Option Explicit
Dim oIPNetwork Dim Hostname Dim result
set oIPNetwork=createobject("SScripting.IPNetwork") hostname=oIPNetwork.Hostname result=oIPNetwork.SendSyslogMessage("syslog.mydomain.local","Hello from " & Hostname) set oIPNetwork=Nothing
My main question is: Is there anything I can do to from a VBA point of view to allow the VBA code within Outlook to run in this 64 bit environment and still make calls to sscrrun.dll?
Alternatively, has anybody got this to work from a WSH point of view in a 64 bit environment?
Thank you.
Dave.
|
Rank: Administration Groups: Administration
Joined: 4/22/2008 Posts: 136
|
Hi Dave,
>My main question is: Is there anything I can do to from a VBA point of view to allow the VBA code within Outlook to run in this 64 bit environment and still make calls to sscrrun.dll?
SSR 1.5, which is currently available for download, also includes x64 versions of the ActiveX-Components. Did you try to use them already?
-Franz
|
Rank: Newbie Groups: Member
Joined: 10/30/2009 Posts: 2 Location: Christchurch, New Zealand
|
Franz, Many apologies, the copy I was working from didn't contain the x64 folder and so I assumed it was 32 bit only. Thank you very much for releasing the utility in the first place.
Dave.
|