Yes and what I am trying to do is to use this as a standard module and not as a Class Module. When I create a new module and put the script in and try to run it a dialogue box come up asking for the macro name.

If I change Sub C6_To_P_If_A(WkSht As Worksheet) to Sub C6_To_P_If_A() and run it I then get a compile error. Not sure what I am doing wrong to make it work from a standard module