DailyRate.Class1 Class
Functionally, this program calculates the commission fee by requesting 2 inputs from the user ( daily rate, number of days )

Access: Project
Base Classes: Object
  Members Description  
    Main Main entry point, serves to catch all unanticipated exceptions

 
    writeExceptionMessage Write exception message to console

 
    run Called from Main, contains top most logic of program and handling all anticipated exceptions

 
    readDouble Read and validate a double from user

 
    readInt Read and validate an integer from user

 
    calculateFee Compute consulting fee

 
    writeFee Write consulting fee to console

 
Remarks:
This class also serves the following learning purposes: 1) Catching exceptions, anticipated and unanticipated 2) Use of comment tags 3) Use of fxcop ( //www.gotdotnet.com/team/fxcop ), a code analysis tool Changes marked "fxcop" in the comments were motivated by the tool. The advantage is that security and more advanced practices are caught and learnt earlier 4) A simple test driver and test data files is used in runtest.bat