Showing posts with label VBScript. Show all posts
Showing posts with label VBScript. Show all posts

[VBScript] Type your text and convert it to speech

Here is a very simple VBScript to convert your text into audio. Type the following code in notepad:

    Dim m,s
    m=InputBox("Enter your text","Say It!")
    Set s=CreateObject("sapi.spvoice")
    s.Speak m

Save this file as "txtspeech.vbs" (with quotes) and double click to run. Type your text and click OK. 



It will be heard as audio.

[VBScript] A very simple virus to crash any system

Following is a very simple VBScript that will crash your computer. Now obviously crash does not mean that it would blast or something. It simply means that it would open a lot and lot of notepads such that your computer will stop responding or will respond like a snail for sometime due to overuse of CPU and RAM resources. The obvious solution is restarting your system.

  • Copy the following code in notepad:
  • Set Ws = WScript.CreateObject("WScript.Shell")
    do
    Ws.Run "notepad.exe"
    loop
    
  • Save the file as "infinitenotepads.vbs" (with quotes i.e. a file with any name and extension .vbs)
  • Open this file by double clicking and see the 'magic'.

A prank virus that opens a notepad and types automatically

Make the notepad type text automatically. Here are the steps:
  • Type the following code in notepad:
  • WScript.Sleep 2000
    Set WshShell = WScript.CreateObject("WScript.Shell")
    WshShell.Run "notepad"
    WScript.Sleep 100
    WshShell.AppActivate "Notepad"
    WScript.Sleep 500
    WshShell.SendKeys "H"
    WScript.Sleep 500
    WshShell.SendKeys "e" 
    WScript.Sleep 500
    WshShell.SendKeys "l"  
    WScript.Sleep 500
    WshShell.SendKeys "l" 
    WScript.Sleep 500
    WshShell.SendKeys "o " 
    WScript.Sleep 500
    WshShell.SendKeys "A" 
    WScript.Sleep 500
    WshShell.SendKeys "r" 
    WScript.Sleep 500
    WshShell.SendKeys "e " 
    WScript.Sleep 500
    WshShell.SendKeys "Y" 
    WScript.Sleep 500
    WshShell.SendKeys "o"  
    WScript.Sleep 500
    WshShell.SendKeys "u " 
    WScript.Sleep 500
    WshShell.SendKeys "f" 
    WScript.Sleep 500
    WshShell.SendKeys "r" 
    WScript.Sleep 500
    WshShell.SendKeys "e" 
    WScript.Sleep 500
    WshShell.SendKeys "a" 
    WScript.Sleep 500
    WshShell.SendKeys "k"  
    WScript.Sleep 500
    WshShell.SendKeys "e" 
    WScript.Sleep 500
    WshShell.SendKeys "d " 
    WScript.Sleep 500
    WshShell.SendKeys "o" 
    WScript.Sleep 500
    WshShell.SendKeys "u" 
    WScript.Sleep 500
    WshShell.SendKeys "t"  
    WScript.Sleep 500
    WshShell.SendKeys "?"
    
  • Save the file with "autotype.vbs" (i.e. file with any name with extension .vbs)
  • Open this file to run the trick.

Simple Message Box to annoy your friends using VBScript

VBScript (Visual Basic Script) is a scripting language developed by Microsoft. It is a lightweight Active Scripting Language with a very fast interpreter.


Here is a very simple VBScript code to annoy your friends. This code will pop up an annoying message box again and again. Here are the steps:

a) Type the following code in notepad:

msgbox("Hello There!")
do
msgbox("Hello again!")
loop

b) Save this as "CoolMsgBox.vbs" (with quotes i.e. a file named CoolMsgBox with extension .vbs)

c) Double Click on this file to view the Message Box.

HOW TO STOP THIS SCRIPT:

a) Open Task Manager. (Ctrl + Shift + Esc)

b) Click on Processestab.

c) Look for a process named 'wscript.exe' , click on it and Click End Process.

d) Click End Process again in the dialog box 'Do you want to end the process wscript.exe?' and the job is done.