ASP.NET Code
  Home arrow ASP.NET Code arrow ASP.NET Basics (part 3): Hard Choices
ASP Free Forums 
.NET  
ASP  
ASP Code  
ASP.NET  
ASP.NET Code  
BrainDump  
C#  
Code Examples  
Database  
Database Code  
IIS  
Microsoft Access  
MS SQL Server  
Silverlight  
Visual Basic.NET  
Windows Scripting  
Windows Security  
XML  
Mobile Linux 
App Generation ROI 
IBM® developerWorks 
ASP Web Hosting  
ASP.NET Web Hosting 
Windows Web Hosting
 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
ASP.NET CODE

ASP.NET Basics (part 3): Hard Choices
By: Harish Kamath (c) Melonfire
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 4 stars4 stars4 stars4 stars4 stars / 35
    2003-08-19

    Table of Contents:
  • ASP.NET Basics (part 3): Hard Choices
  • Apples And Oranges
  • Do It Or Else...
  • Cookie-Cutter Code
  • Three In One
  • Friday The 13th
  • Switching Things Around
  • Endgame

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    ADVERTISEMENT


    ASP.NET Basics (part 3): Hard Choices


    (Page 1 of 8 )

    In this third part of our introductory ASP.NET tutorial, learn all about C#'s logical and comparison operators with simple examples and illustrations. And while you're at it, get a crash course in adding decision-making logic to your ASP.NET programs with C#'s numerous conditional statements, including the "if", "if-else" and "switch" statements.With a little bit of luck, my previous article on C# left you so excited that you spent the last two weeks eagerly practicing variable names and letting your friends know how much smarter than them you are. And this week, I'm going to help you cement your reputation still further, by giving you a crash course in C#'s conditional statements.

    I'll start with a gentle introduction to the comparison operator - the backbone for implementing a conditional statement. Next, I'll be introducing you to the most common conditional statement - the "if" statement. This is followed by the other members of the "if" family, namely the "if-else" and "if-else if-else" conditional statements. Finally, I'll show you how to get to grips with the "switch" conditional statement, the tool of choice when you want to avoid multiple "if-else if-else" branches in your code.

    Make sure you're strapped in tight - this is gonna be one hell of a ride!

    More ASP.NET Code Articles
    More By Harish Kamath (c) Melonfire


     

    ASP.NET CODE ARTICLES

    - How to Use the ListBox Control in ASP.NET 2.0
    - How to Load XML Documents in ASP.NET 2.0
    - DataGrid Code
    - ASP.NET Guestbook
    - User Controls and Client Side Scripting
    - ASP.NET Programming with Microsoft's AS...
    - ASP.NET Basics (part 3): Hard Choices
    - ASP.NET Basics (part 2): Not My Type
    - ASP.NET Basics (part 1): Nothing But .Net
    - Directory Tree Browser
    - How to get the confirmation of Yes/No from a...
    - Complete example using custom errors and wri...
    - Paging Certain # records per page .NET style
    - General Methods of formatting and Subtractin...
    - .NET LinkButton web control





    © 2003-2009 by Developer Shed. All rights reserved. DS Cluster 2 Hosted by Hostway
    Stay green...Green IT