Yes, that seems to be the problem. I removed all 'Set' and was more explicit about the types. It's very confusing that

Dim A, B As Integer
does not declare two integers... since it is not, it should not even be allowed input.

But hey, it's just Microsoft, so who cares?

Thanks,

Hinnerk