There
are many times when you wanted something interactive from your
computer. For fun you can build this application, which is too easy.
This can also save your money as there are some app which asks for
money. So this will be awesome for you! I am going to guide you about
how to make an Notepad application that speaks. This application
basically works on "visual basic coding" Before starting up I will teach
you some important things, the things you need to learn is what each
statement does.
The
Image above is the actual notepad coding that you are going to learn.
Before making any application it is necessary to learn the small things.
You must know that what does each line exactly do. As it will going to
help you if you wanted to edit you app yourself. So In the next
paragraph I will explain you each line! Below is the image marked with
numbers. In same numerical order I will be guiding you!
1st Line --> This line is the title of your application. If I will use this code then the title will be Speak. The Word Dim Message tells that following is the title. Comma(Symbol) tell that now we are writing the title. There is no need of any mark to tell the ending of the title!
2nd Line --> This line shows the text that appears in your application. The text which is just beside the "OK" and "Cancel" button. You can edit this text and you can add anything you want, but be sure you add the text in one line only, means no second line in notepad!
3rd Line --> This line creates those buttons ( Cancel & OK) and the support for enter key! You can also ask to speak by just pressing enter key! This is the most important line, if you miss it nothing will work!
4th line --> This line make the text speakable. When you press enter this line convert the text into audible form. In this line Message is the text that you have typed!
Below I have pasted an image that shows you the output from the input. The input is shown in the image above and the output is in the image below
So
now you have got the main idea that how this coding works. Now we will
begin the main process. First of all you have to open Notepad. After
opening the notepad copy the following code.
The Code
1
2
3
4
5
6
7
8
9
10
| Dim Message, Speak Message=InputBox( "Type anything into the text box below & hit enter By Cerefo.hubpages.com " , "Speak" ) Set Speak=CreateObject( "sapi.spvoice" ) Speak.Speak Message |
After copying paste it in the notepad. Now if you want to make any changes then make it now only. After editing save the file with the name "talking.vbs" and in "save as type" option choose "all files" now click on save button. Now go to the place where you have saved your file and open it. Voila, You have created your own application. Have fun! Now just type anything and hit enter.!
If you face any problem just comment it don't hesitate to do so! Feel free
Tips And Tricks!
You
can also have fun with this application. Just type any letter many
times about 200-300 times(you can copy and paste) and hit enter. You
will get an annoying sound. If you want to irritate someone use this
trick. WARNING: Do not type any letter too many times,
if you do so then the computer will create too much annoying sound and
at last you have to shut it down!
Comments
Post a Comment