The ScriptConverter Tool demo
About The ScriptConverter Tool
OPTION EXPLICIT on error resume next on error goto 0 DIM dct SET dct = CreateObject("Scripting.Dictionary") SET dct = nothing 'SUB window_onload() call fnJoke("Why'd the chicken cross the road?", answer()) 'END SUB Function answer() answer = "GOTO 10" END FUNCTION SUB fnJoke(p_strJoke, p_strPunchline) DIM strName, strPrompt strName = inputbox("What's your name?", "important thing", "Anonymous") strPrompt = "Hello " & strName & ", wanna hear a joke?" IF msgbox(strPrompt, vbOKCancel)=vbOK THEN msgbox p_strJoke & vbCRLF & vbCRLF & p_strPunchline ELSEIF strName="Anonymous" THEN ' tell it anyway msgbox "i'll tell ya anyway." & vbCRLF & _ p_strJoke & vbCRLF & vbCRLF & p_strPunchline ELSE ' doesn't wanna hear it call msgbox("you are a PARTY POOPER, Mr. " & strName & "!") END IF END Sub fnJoke() CONST testing = 2 SELECT CASE testing CASE 1 msgbox ucase("one") CASE 2: msgbox lcase("two") CASE 3 msgbox isNumeric("three") END SELECT
clear
run!
script input
-
o
+
VBS to JS
JS to VBS
C
onvert >>
copy
clear
run!
script output
OPTIONS:
collapse string concatenation