PDA

Click to See Complete Forum and Search --> : This is getting serious people! #2


Sep 28th, 2000, 05:37 PM
Take a look at this thread (http://forums.vb-world.net/showthread.php?threadid=28673)!

It's really getting serious, and it's not just Yonatan :rolleyes:! My name is spelled Matthew Gates. Two t's! Not one!

'Author: Yonatan
Origin: http://forums.vb-world.net/showthread.php?threadid=28673
'Purpose: Get's Matthew's name right
'Version: VB4+

Private Sub cmdName_Click()

Dim ShutUp As Boolean, MyName As String

MyName = StrConv(InputBox("What's Matthew's name???"), vbProperCase)

If Not Len(MyName) = 7 Then
Call MsgBox("That's not Matthew's name!", vbCritical)
Exit Sub
End If

' I could have written: If Not MyName = "Matthew" Then ShutUp = True
' But I didn't! Instead, I used Left, Mid and Right, and even indented it so it can be read top to bottom.

If Not Left(MyName, 1) = "M" Then ShutUp = True '
If Not Mid(MyName, 2, 1) = "a" Then ShutUp = True '
If Not Mid(MyName, 3, 1) = "t" Then ShutUp = True '
If Not Mid(MyName, 4, 1) = "t" Then ShutUp = True '
If Not Mid(MyName, 5, 1) = "h" Then ShutUp = True '
If Not Mid(MyName, 6, 1) = "e" Then ShutUp = True '
If Not Right(MyName, 1) = "w" Then ShutUp = True '

If ShutUp Then
Call MsgBox("That's not Matthew's name!", vbCritical)
Else
Call MsgBox("WOO! WOO! You finally got Matthew's name right! You actually typed Matthew!", vbExclamation, "Hallejuia!")
End If

End Sub



[Edited by Matthew Gates on 09-29-2000 at 02:15 PM]

Yonatan
Sep 29th, 2000, 08:08 AM
WOO! Leet copy & paste skills!

Originally copied and pasted by Matthew Gates

' Because the 1st letter is: Y
' Because the 2nd letter is: o
' Because the 3rd letter is: n
' Because the 4th letter is: a
' Because the 5th letter is: t
' Because the 6th letter is: a
' Because the 7th letter is: n


You'll get over it. :rolleyes:

Sep 29th, 2000, 01:18 PM
Where do you see that? And you are the author. The code looks advanced, even though something simple would do the trick.

And yes, copy and paste are wonderful things :rolleyes:.

Yonatan
Sep 29th, 2000, 01:25 PM
Where do you see that?


[Edited by Matthew Gates on 09-29-2000 at 02:15 PM]

Riiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiight. :rolleyes:
I saw it before 09-29-2000 at 02:15 PM.
And, there are still empty comments in the place where mine were. You forgot to remove the little ' marks.
Now you're probably going to edit it again. :rolleyes:

Sep 29th, 2000, 01:54 PM
Nah, I don't need to edit, the ' comments won't hurt :rolleyes:. And plus, you already know ;-x.

So remember, always spell Matthew with two t's!
And if everyone starts spelling it correctly,
I can die happy! :D