-
November 5th, 2002, 10:11 AM
#1
Can't execute ANY VBScript
Hi all,
Below is a HTML file. It contains VBScript to display a messagebox. Can
anyone see any obvious reason why it doesn't display the messagebox? I've
converted it to Javascript (ie. alert("Hello") and it works fine. I've
also tried looking though the security settings to see if there was any
VBScript specific settings there and couldn't find any.
Any thoughts/solutions appreciated,
Rob
<html>
<head>
<title>Untitled</title>
</head>
<body>
Start
<Script Language="VBScript">
msgbox "Hello"
</SCRIPT>
End
</body>
</html>
If at first you don't succeed, skydiving is not for you.
-
November 5th, 2002, 12:37 PM
#2
Additional Info
This problem only occurs on 1 PC out of about 20.
All have VBScript V.5.5.0.5207 installed.
The VBScript code is being ignored in the same way it would if I had inserted the line <Script Language="DontExist"> instead of <Script Language="VBScript">
If at first you don't succeed, skydiving is not for you.
-
November 5th, 2002, 03:00 PM
#3
Could you provide more info...
This is obviously not an ASP page otherwise you would
have done:
<%@ LANGUAGE=VBScript %>
<%
msgbox "Hello"
%>
So if it's not an ASP architecture why are you trying to use VBScript? Do all of the PC's have the same version of Internet Explorer installed?
-
November 6th, 2002, 04:40 AM
#4
No, it's not an ASP page. The Web Page I have problems with creates an Excel Chart client-side. I know, I know, I should install Office Web Classes on the Server. However, try telling our computer services department that!!! So, back to the problem. The WebApp will only ever be used on our company intranet. All PC's have Office 97 installed so there should be no trouble with people generating charts. However, client-side VBScript is simply ignored. Server-side script (used in other pages) is fine. As I mentioned, the problem only occurs on 1 PC out of 20. I'm at a loss to understand why because all the IE security settings are the same for all PC's (same version of IE on all PC's as well).
If at first you don't succeed, skydiving is not for you.
-
November 7th, 2002, 02:55 AM
#5
Security Settings
Intranet Security Settings are:-
ActiveX controls and plug-ins : All Enabled
Cookies : All Enabled
Downloads : All Enabled
Java Permissions : Medium Security
Miscellaneous
Access data sources across domains : Prompt
Dont promp for client certificate... : Enable
Drag and drop or copy and paste files : Enable
Installations of desktop items : Prompt
Launching programs and files in an IFRAME : Prompt
Navigate sub-frames across different domains : Enable
Software channel permissions : Medium safety
Submit nonencrypted from data : Enable
Userdata persistence : Enable
Scripting : All Enabled
User Authentication
Logon : Automatic logon only in Intranet zone
If at first you don't succeed, skydiving is not for you.
-
November 12th, 2002, 01:17 PM
#6
Do you have Host Scripting support installed on the computers that are having problems? If I remember correctly, scripting won't work (specficially, VBScript) if you don't.
- Shawn
MCP, VB6: Desktop Apps
[ C# | VB | .NET | Java | VC++ | Perl | PHP | Javascript ]
Unless otherwise stated, all sample code provided is UNTESTED.
http://www.codemastershawn.com
-
November 12th, 2002, 01:20 PM
#7
Also, try moving the <script> tag into the <head> and then calling your code from the body onLoad event. It's been a long time since I've toyed with VBScript (seldom used any more, in my experience) but I'm not sure you can use it in-line in the HTML like that.
- Shawn
MCP, VB6: Desktop Apps
[ C# | VB | .NET | Java | VC++ | Perl | PHP | Javascript ]
Unless otherwise stated, all sample code provided is UNTESTED.
http://www.codemastershawn.com
-
November 13th, 2002, 04:20 AM
#8
Hi ShawnDev,
I sidestepped the problem in the end my rewriting my function as JavaScript. I had already tried moving the code into the <Head> section but to no avail. Really was quite bizzare. To the best of my knowledge, all the PC's had the same security settings, yet it only failed on one of them. Someone suggested IE/VBScript DLL might have become corrupted which seemed to be the only other possibility (one which I couldn't check because I only have Admin rights for my PC so can't install/reinstall software on anyone elses).
Cheers for the response anyway,
Rob
If at first you don't succeed, skydiving is not for you.
-
November 13th, 2002, 11:10 PM
#9
Glad you got it working.
Abandoning VBScript is always the right answer
(No, not really - don't send me hate mail. It's a joke, son.)
- Shawn
MCP, VB6: Desktop Apps
[ C# | VB | .NET | Java | VC++ | Perl | PHP | Javascript ]
Unless otherwise stated, all sample code provided is UNTESTED.
http://www.codemastershawn.com
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|