CheckAndSavePKey returns error code 1

So here is the situation:

1)IsGenuineEx returns TA_FAIL2)I prompt the customer to insert their key and I call CheckAndSavePKey(key, TA_SYSTEM); it returns error code 1 again

The customer is literate when it comes to computers. They have full admin rights and they say previous version of the program (when I didn't call IsGenuineEx but only IsActivated) worked correctly.I've searched the forum and made the customer to remove those key files - to no avail still the same error code 1 when calling CheckAndSavePKey(key, TA_SYSTEM).I made the customer to turn on UAC on (it was off before) - still no change. Any ideas what else I can try?

After IsGenuineEx() returns TA_FAIL, are you then checking IsActivated() to see if the customer is activated (but failed to connected to the servers to reverify their license)?

If not, do that. A customer cannot use another key to activate when they already have a different key activated. My guess is that this is what's happening.

Only after doing that, then check if the customer is copying & pasting the key correctly. That they have the right key and that they're putting it in the right place. Do a remote login with the customer to determine that

>>After IsGenuineEx() returns TA_FAIL, are you then checking IsActivated() to see if the customer is activated (but failed to connected to the servers to reverify their license)?

Well, I am still confused apparently. From last exchange I thought I am only supposed to call IsActivated in case the IsGenuineEx returns either TA_E_INET or TA_E_INET_DELAYED. If I call IsActivated after getting TA_FAIL from IsGenuine it defeat the point of an online check, doesn't it?

>>If not, do that. A customer cannot use another key to activate when they already have a different key activated. My guess is that this is what's happening.

is there a way for me to remove all keys from the computer so the customer can try "clean" registration? This customer has a lot of computers in several locations so it's likely something got messed up here.

>> then check if the customer is copying & pasting the key correctly. That they have the right key and that they're putting it in the right place. Do a remote login with the customer to determine that

Yes, this I've already verified by doing screen sharing.

I am sorry for confusion. I do call IsActivated after TA_FAIL is returned from IsGenuineEx and that returns TA_FAIL (well, something different than TA_OK) as well.I should probably read the error code from IsActivated as well.

Ok... so is CheckAndSavePKey() failing (just generally, and you don't know what the error code is), or is it actually returning TA_FAIL?

>>Ok... so is CheckAndSavePKey() failing (just generally, and you don't know what the error code is), or is it actually returning TA_FAIL?

CheckAndSavePKey() is failing with specifically TA_FAIL (error code 1).What I don't know is what is IsActivated() fails with I konw that:

1)IsGenuineEx() returns TA_FAIL specifically2)after that IsActivated returns something different than TA_OK3)after that CheckAndSavePKey() return specificially TA_FAIL

The customer confirms it's very possible they activated different key on this machine before. If that could cause problems it would be the best if I could somehow reset all the keys and ask them to activate again.Or maybe it's some Windows service which needs to be on for CheckAndSavePKey to work?Any more guesses?

I investigated more (by catching IsActivated exact error code as well) and that explained everything (the customer had wrong files).I am very sorry for wasting your time.

Have a nice day!

I'm glad you figured it out. 🙂