Jump to content


This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
Photo

VBScript or JScript


2 replies to this topic

quakey

quakey
  • Full Members
  • 33 posts

Posted 01 December 2004 - 02:59

Hi,

I noticed that we can call embedded VBScript and JScript in MSI. Which one is
preferred? I mean they both require runtime installed on the destination computer
and which one is most commonly installed? Also, what happens if the destination
computer doesn't have niether one of them installed.

Thanks!

Zweitze

Zweitze
  • Full Members
  • 522 posts

Posted 01 December 2004 - 10:14

Both languages are installed with the Windows Scripting host. This is available as a separate download, and also part of Internet Explorer 4.0 (maybe even 3.0). So, if you have one, you have the other as well.
There's no big difference between the languages - use the language that matches your programming style. Get the documentation from http://msdn.microsoft.com/scripting.
When Active Scripting is not installed, and your CA is a VBScript or JScript CA, the install aborts with run-time error 2738 or 2739. This can happen on Windows 95 or NT 4.0 systems without Internet Explorer, but I've also heard about a few Windows XP systems where Active Scripting was removed one way or another (I have no idea how one can do that).

Note: If you intend to write scripts that access FileSystemObject, consider writing a DLL instead. Norton Antivirus has a feature called script blocking, which kicks in when you use the FileSystemObject.

quakey

quakey
  • Full Members
  • 33 posts

Posted 01 December 2004 - 19:54

QUOTE (Zweitze @ 2004-12-01 10:14)
Both languages are installed with the Windows Scripting host. This is available as a separate download, and also part of Internet Explorer 4.0 (maybe even 3.0). So, if you have one, you have the other as well.
There's no big difference between the languages - use the language that matches your programming style. Get the documentation from http://msdn.microsoft.com/scripting.
When Active Scripting is not installed, and your CA is a VBScript or JScript CA, the install aborts with run-time error 2738 or 2739. This can happen on Windows 95 or NT 4.0 systems without Internet Explorer, but I've also heard about a few Windows XP systems where Active Scripting was removed one way or another (I have no idea how one can do that).

Note: If you intend to write scripts that access FileSystemObject, consider writing a DLL instead. Norton Antivirus has a feature called script blocking, which kicks in when you use the FileSystemObject.

Thanks! Great explination.