Setting extradata/server check/graceperiod for offline activation

I am assuming that before calling ActivateProduct() the following line would be added immediately beforehand

LexActivator.SetExtraActivationData(System.Environment.MachineName);

When activating offline, is it placed immediately before calling GenerateOfflineActivationRequest(filepath) so as to be incorporated in the key on the console?

In the case of the following two lines, as I am assuming they are saved locally to the machine, can they be called at any time, or do they need to be just before ActivateProduct() or ActivateProductOffline(filepath)

LexActivator.SetDayIntervalForServerCheck(0);
LexActivator.SetGracePeriodForNetworkError(0);

I would only want the server check and grace period data set as shown, if there was a successful offline activation. The values would be different for an online activation.

Thanks

Hi,

“When activating offline, is it placed immediately before calling GenerateOfflineActivationRequest(filepath) so as to be incorporated in the key on the console?”

Yes, it has to b set before the above call.

LexActivator.SetDayIntervalForServerCheck(0);
LexActivator.SetGracePeriodForNetworkError(0);

Can be set anytime. Depending on whether the activation was online or offline you can set the value accordingly.

Thanks