


VVal = Text_string_containing_values_for_Feet_Inches ' \ These values are used to examine the input string, one character at a time Dim vVal As String ' \ shorter name for input string Dim i As Integer ' \ counter to step through each character in input string Dim vChar As Variant ' \ temporary storage of each input string character ' \ These variables hold the values we discover for feet, inches and the ' \ numerator and denominator of the fractional inches Dim iFt As Integer ' \ used to store number of feet Dim iIn As Integer ' \ number of inches Dim iNumerator As Integer ' \ numerator of fractional inches Dim iDenominator As Integer ' \ denominator of fractional inches ' \ In the process of discovering values for feet and inches, these variable ' \ are used to accumulate and hold numeric values Dim iTemp As Integer ' \ Used to build a number as each digit is read ' \ We want to ignore spaces, except for the very important space between ' \ the number of inches and the numerator of the fractional inches ' \ This variable is true if the last character processed was a space Dim bLastCharWasSpace As Boolean ' \ First we assign input string to variable with shorter name

Function CInches(Text_string_containing_values_for_Feet_Inches) Option Explicit ' \ This function converts a string like 5'-6 1/4" to a decimal number ' \ of inches that can be used in calculation.
