locked
Beginner question about visual basic RRS feed

  • Question

  • I am very new to Visual Basic and I am trying to teach myself using a tutorial guided book called Simply Visual Basic 2008. I am also very new to this community so not sure where I should post :\

    One of the examples that I am trying to complete involves changing some of the source code provided by the authors.

    The question says Use an If... Then selection statement to avoid division by zero and display a message dialog to the user if there are no grades entered when the user clicks the average button.

    I have changed the code so that it will display a message when no grades have been entered, but it will then procede to finish the rest of the sub and error during debug mode.  I have a feeling the error is happening because there is nothing to divide and division by 0 is messing up the compiler.  Thanks in advance for any help, I will greatly appreciate it.
    Sunday, March 8, 2009 6:56 AM

Answers