Hey I'm doing coursework in VB 6 and the task is to:

  • allow a user to enter numbers in Roman numerals, according to the additive rule, each up to a maximum value of 4000 (MMMM)
  • prevent the user entering an invalid Roman numeral
  • display the numbers entered in both Roman numerals and their Arabic decimal equivalent
  • allow the user to enter an operator for addition or subtraction
  • prevent the result of a subtraction being zero or a negative number
  • display the result of the calculation in both Roman and Arabic decimal forms
  • allow the user to clear all displays


The additive rule in this case is to make sure that you enter numerals in descending order of value and a letter may not be repeated if it can be replaced (e.g. IIIII can be replaced with V). In this question 4 is classed as being IIII and NOT IV.

I've created an inteface that allows the user to enter an already valid Roman numeral (i.e. not validated by the program itself), it displays the numbers and answers in both numeral and decimal forms, the user can add or subtract the numerals and there is an option to clear all displays.

But I'm having problems trying to write the validation rules for:

  • making sure the numeral that is entered is in the correct order
  • the additive rule (explained above)


If anyone can help it would be much appreciated! Thanks!

xtishx