Java TurboActivate.Deactivate() returns 24

Having issues deactivating on Java using Linux OS.

App was activated using: TurboActivate.CheckAndSavePKey(key); TurboActivate.Activate();

int ret = TurboActivateNative.INSTANCE.Deactivate((byte)(eraseProductKey ? 1 : 0));returns // 24

switch (ret) { case 2: // TA_E_PKEY throw new InvalidProductKeyException(); case 3: // TA_E_ACTIVATE throw new NotActivatedException(); case 4: // TA_E_INET throw new InternetException(); case 8: // TA_E_PDETS throw new ProductDetailsException(); case 11: // TA_E_COM throw new COMException(); case 0: // successful return; default: throw new TurboActivateException("Failed to deactivate."); }

You've limited the number of deactivations for the product key. So increase the limit. From TurboActivate.h:

/* MessageId: TA_E_NO_MORE_DEACTIVATIONS Message code (in Hex): 0x18 Message code (in Decimal): 24


 MessageText: This product key had a limited number of allowed deactivations. No more deactivations are allowed for the product key. This product is still activated on this computer.*/#define TA_E_NO_MORE_DEACTIVATIONS    ((HRESULT)0x00000018L)

Thank for the quick response.

Is there a special way to get it to activate under tomcat? If I run the server as root it activates ok but return TA_FAIL when running as tomcat6 user.

TurboActivate.VersionGUID = "5sdfsdfsfsdfsdf.sdfsdfsdfsdfsdf";

TurboActivate.SetPDetsLocation();TurboActivate.CheckAndSavePKey(key);TurboActivate.Activate();

here is my custom output in the catalina log:

TurboActivate: Saving PKEY:MZHI-HVEM-C2SG-......

productKey:[MZHI-HVEM-C2SG-.......] return: 1

TurboActivate failed: The product key is invalid or there's no product key.

Is this related to the deactivation issue? Or is this a new questions. If this is a new question then...

1. Are you using the latest verison of TurboActivate?

2. Is the product key actually for that version of your app in LimeLM?

3. Make sure the Java app actually has permission to write to the computer. If you're running in Tomcat that may or may not be true.

Yes, new question.

The deactivate issue I solved by setting it to unlimited, it was set to 0.

Is there a specific path that the java app need write access to?

I'm using newest TurboActivate-Linux API files just downloaded yesterday.

The product key and GUID are working correctly since I can activate under root.

Try using TA_SYSTEM when calling CheckAndSavePKey(). Also, make sure you run CheckAndSavePKey() with TA_SYSTEM at least once from an admin account.