OK step by step:
1. go to start, programs, acessories, notepad - notepad is basic program for writing in windows, everyone has it
2. write: (or copy and paste it)
answer=msgbox ("is your name John?" ,4)
3. click "save as"
4. in "file name" insert:
whatever.vbs
no matter if default is .txt! simply delete .txt and write in .vbs
other things dont matter!
5. go to place where you saved it and 2x click it.
that is it if error appears, it says something like:
script: place where document is saved
line: number of line, where error was dectected
char: number of character (letter, number...) Where mistake is
error: What is wrong like "Expected sign ")""
code: some code
source: im not sure
find the place where mistake is and try to fix it yourself. If you copied text from this post it should work, since i tried it out.
WARNING in my last post I have written:
msgbox ("Is your name John?" ,4)
THIS IS WRONG!
It should say
answer=msgbox ("is your name John?" ,4)
You can replace "answer" with anything you want, since it is only there as a name for returned information
Now I will write something larger:
answer=msgbox ("Is your name John?" ,4)
if answer=6 then
msgbox "What a wonderful name!"
else
fname=inputbox ("No? what is it then?")
msgbox ("Oh its " &fname)
end if
Now Ill explain it:
1. line: you already know it, but anyway! creates a message box with YES and NO the information that will be returned will be called "answer" because, we told it to be so with "answer="
2. line: I think you understand what this line means - if the answer on my question is 6 (6 means YES, 7 means NO) then... So I wont explain too much more "is" is always replaced with "=" we used "answer because we also used it in 1. line. But if we would use "info" instead of "answer" in line 1, we would have to use "info here too" get it?
3. line: this line doesnt have to be in new line. It can be written next to "else", but I always put it in a new line, since its easier to find it. It says what should happen "if answer=6" so now we have the whole sentence "if the answer is 6 (YES) than create a message box, saying "What a wonderful name!" I hope you understand it!
4. line: this line is short but very important "else" means: If its not. So we could also write "if answer=7 then" (7 means NO) but its easier and shorter if we use "else"
5.line: Now heres something new! "fname" is like "answer" but it indicates different information. "answer" means YES or NO, while "fname" means whatever you will write in the place, where you have to write the answer (in this case your name)You can change "fname" to whatever you want as well!
next is "inputbox ("No? What is it then?")"
that simply creates a box where you can input text with message "No? What is it then?"
6. line: here we have "msgbox ("Oh your name is " &fname)
"msgbox" means create a message box, "Oh your name is " is what the message should say and "&fname" means computer has to insert "fname"- the information you have entered in the last box.
7. line: the last line says "end if" this simply means THE END you have to put it at the end of text, or you will get an error.
So thats it!
I hope I explained good enough! Its quite complicated and im not that good at explaining stuff. Its also difficult, because I am not from england or any other english speaking country, and im also only teen! So im sorry for any mistakes at writing and dont be too angry if you dont understand it - it is complicated :wink: