Prelab07 - General Function: ValidateInput( ) Write a...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
CNIT 175 Prelab07 Objectives: Do While Loop Do Until Loop For Next Program: Design a VB project in which the user enters a whole number, N as input, and clicks on a Button to compute: Sum of all numbers from 0 to N (Use a Do-while loop) Sum of even numbers from 0 to N (Use a For-Next loop) Sum of odd numbers from 0 to N (Use a Do-Until loop)
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: General Function: ValidateInput( ) Write a general function to validate the entered data for being a whole number greater than 0. This function should return a Boolean output. Invoke this function from the click event of each Button before processing the input. Figure 1 Screen capture at runtime...
View Full Document

This note was uploaded on 02/06/2012 for the course CNIT 175 taught by Professor Na during the Fall '11 term at Purdue University-West Lafayette.

Ask a homework question - tutors are online