Let's see if we can get you started at least. Start Excel and go to the
worksheet that has your "fractions" on it. Now, right-click the worksheet's
tab at the bottom of the page and select View Code from the popup menu that
appears. This will take you to the VB editor, and specifically, to the code
window for the worksheet you were on when you right-clicked the tab.
Copy/Paste the following code into that code window...
' ***** Start of Code *****
Sub Solve(R As Range)
Dim C As Range
On Error Resume Next
For Each C In R
C.Value = Application.Evaluate(Replace(LCase$(C.Value), "x", "*"))
If IsError(C.Value) Then C.Clear
Next
End Sub
Sub SolveCellExpressions()
Solve Range("A1:A10")
End Sub
' ***** End of Code *****
Okay, now go back to the worksheet (click File/Close and Return to Microsoft
Excel on the VB editor's menu bar). Type some of your "fractions" and other
expressions (remember, they can be more complicated than simple fractions if
desired) that you want converted into any of the cell in the range A1:A10
(notice, that is the range specified in the subroutine named
SolveCellExpressions). Here are some to get you started...
A1: 7/8 x 2 1/4
A2: Sqrt(1/4)
A3: Sin(0.523598775598299) + 1 1/2
{Answers.... A1 = 1.96875, A2 = 0.5, A3 = 2}
Once you have typed as many expressions as you want in the first 10 cells of
Column A, press Alt+F8 and select SolveCellExpressions from the list that
appears. Next click the Run button and watch what happens to the entries in
the range A1:A10. Hopefully, if all went well, those expressions you typed
in should have been converted to their evaluated values.
Rick