Okay today I had to sign a .NET assembly within Visual Studio. First problem was that I became only a pvk and a spc key files but Visual Studio want’s a pfx. So I converted the files with pvk2pfx and tried it, but this failed with the message “Cannot find the certificate and private key for decryption”.
A google search turned up the solution you have to import the key into the cert store and then export it as described in the above link. The newly exported pfx key should work (at least it did for me).