{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

Chapter03 Slides - Chapter 3 Writing Programs First You...

Info icon This preview shows pages 1–13. Sign up to view the full content.

View Full Document Right Arrow Icon
Opportunity Click to edit Master subtitle style Chapter 3: Writing Programs First You Walk, Then You Run MIS 304: Introduction to Problem Solving and Programming
Image of page 1

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
You will learn how to… Describe the programming sequence using the acronym, IPO Compare controls, events and properties to nouns, verbs and adjectives Add comments and program headers to describe code Properly format numeric output
Image of page 2
You will learn how to… Describe and distinguish between syntax, logical and runtime errors Use properties at design time and runtime to modify controls Convert input and data between various data types
Image of page 3

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
You will learn how to… Complete the entire programming process from problem definition, algorithm development, flowcharting, form design and coding Debug a program using an audit
Image of page 4
Not that kind of IPO… Declarations, Input, Processing, Output Input provides for changes Processing makes changes properties changes values in variables change calculations are made Output is the results of the changes
Image of page 5

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Errors in Your Program Most programs have errors in them Most programs will crash Programming errors fall into three categories Logical errors Syntax errors Runtime errors
Image of page 6
Syntax Errors Computer doesn’t understand the command Spelling or grammatical errors Displays blue, squiggly line under the code Blue line usually, but not always, displays the location of an error Program won’t run with a syntax error Syntax Error
Image of page 7

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Logic Errors Code doesn’t do what you think it should Syntax works – code compiles Output is wrong Potential Sources Errors in thinking Steps in the wrong order Steps missing Wrong formula
Image of page 8
Runtime Errors Program crashes Many causes Human error is the most common Empty TextBox Unexpected input (Ex. abc or 1.3 for quantity) Divide by zero Stack overflow (data type too small) Use error checking methods to prevent runtime errors
Image of page 9

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Runtime Error in VS
Image of page 10
Controlling Your Controls Goal of the developer is to make computing easier for the user Often means more work for a developer The better the interface, the better the user experience
Image of page 11

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Controlling Your Controls Change the StartPosition property to CenterScreen Change the Size property to make the Width = 500 and the Height = 400 Change the Icon property by adding the lighton.ico icon to it Change the BackColor of the form Change the FormBorderStyle to Fixed3D
Image of page 12
Image of page 13
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern