We Exist to Provide 100% Free Source Code and Tutorials

Custom Search

04-If Statement

The If statement is a conditional logic branching in computer programming. It contains the true and false statement in a computer terminology.  The true statement evaluates a nonzero value while the false statement evaluates a zero value.


This conditional logic is not just for computer programming but this can be also used in your daily life without realizing you’re doing it.

For instance, if you know how to catch fish then you have something to eat for the day but if not, you will be hungry the whole day.

Here’s the example of if and else statement:

  1. Dim name as String
  2. name = "Kenjie"
  4. If name= "kenjie" Then
  5. MessageBox.Show( "Name is Kenjie" )
  6. else
  7. MessageBox.Show( "Name is not Kenjie" )
  8. End If
Facebook Comments
(Visited 12 times, 2 visits today)
Share this

Check Your Domain Ranking

Leave a Reply

Your email address will not be published. Required fields are marked * © 2016 Frontier Theme

Subscribe For Latest Updates

Signup for our newsletter and get notified when we publish new articles for free!

%d bloggers like this: