Solved

MSScriptControl in .asp on 64bit server won't work

Posted on 2013-01-25
5
3,110 Views
Last Modified: 2013-01-26
I have an .asp application that uses CreateObject("MSScriptControl.ScriptControl") so it can use the eval method to unescape an encoded string with special characters (ie. %A7).  We work with a lot of foreign languages.  This had worked fine, but when we moved it to a 64 bit server we get the "can't create object" error.

Function Unescape(s) 
    Dim scr 
    Set scr = CreateObject("MSScriptControl.ScriptControl")
    scr.Language = "VBScript"
    scr.Reset
    Unescape = scr.Eval("unescape(""" & s & """)")
End Function

Open in new window


Doing a little searching it appears that there is only a 32 bit version of msscript.ocx.  So, my questions are, (1) how can I make this run on a 64 bit server, (2) is there an equivalent function that can replace msscript, or (3) is there an alternative to decoding strings that works as well.
0
Comment
Question by:StarDusterII
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 29

Expert Comment

by:sammySeltzer
ID: 38822273
Try the following:

Click Start, click Run, type %windir%\SysWoW64\cmd.exe, and then click OK.
Then type
cscript yourVBScript.vbs

More from this link http://support.microsoft.com/kb/896456
0
 

Author Comment

by:StarDusterII
ID: 38822520
You lost me there a bit... this is not a .vbs, it's an .asp (Active Server Page) served by IIS.
0
 
LVL 29

Accepted Solution

by:
sammySeltzer earned 500 total points
ID: 38822547
That code that is asp?

WOW, I thought I knew ASP!

Anyway, for what you described in your original post, my post would have solved it.

However, if your code is asp, then you need to follow this link to enable 32bit mode in iis.

http://help.webcontrolcenter.com/KB/a1114/how-to-enable-32-bit-application-pool-iis-7-dedicatedvps.aspx
0
 

Author Comment

by:StarDusterII
ID: 38822623
Well, the original post started off with "I have an .asp application..." but I guess I could have made that a little clearer.

Anyway, your solution worked fine.
0
 
LVL 29

Expert Comment

by:sammySeltzer
ID: 38822777
Thanks a lot for the points.

Glad it worked for you.
0

Featured Post

Webinar: MongoDB® Index Types

Join Percona’s Senior Technical Services Engineer, Adamo Tonete as he presents “MongoDB Index Types, How, When and Where Should They be Used?” on Wednesday, July 12, 2017 at 11:00 am PDT / 2:00 pm EDT (UTC-7).

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Not long ago I saw a question in the VB Script forum that I thought would not take much time. You can read that question (Question ID  (http://www.experts-exchange.com/Programming/Languages/Visual_Basic/VB_Script/Q_28455246.html)28455246) Here (http…
Lync server 2013 or Skype for business Backup Service Error ID 4049 – After File Share Migration
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…

628 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question