>Sub FormatPrice > Dim oVFP As Object > Dim theLast as string && theLast declared > Set oVFP = CreateObject("VisualFoxPro.Application") > oVFP.Visible = True > oVFP.DoCmd "cd c:\page0\" > oVFP.DoCmd "set procedure to c:\page0\FormatPrices.prg" > Range("A1").Select > theLast = ActiveCell.Value > oVFP.DoCmd "FormatPri()" && Can VFP be aware of the value of theLast > ActiveCell.Value = theLast > oVFP.Quit > Set oVFP = Nothing >End Sub >Steve,
Sub FormatPrice Dim oVFP As Object Set oVFP = CreateObject("myVFPDLL.myClass") Range("A1").Value = oVFP.FormatPri(Range("A1").Value) Set oVFP = Nothing End SubCetin