Attribute VB_Name = "WritePERatioExpected" Option Explicit Function run(row As Integer, content As String) On Error GoTo eh Worksheets(TARGET_SHEET).Range(COL_P_E_RATIO_EXPECTED & CStr(row)).Value = content Done: Exit Function eh: Debug.Print "WritePERatioExpected" Debug.Print row Debug.Print content End Function