Inapp purchase with maintain applications internal variable while user triying to install/ Uninstall application
===

I have developed one application Where user can have 4 trials available for free. when the user uses all the 4 trials and try to use one more trial application ask the user for In app purchase to spent 0.99 $ for another 4 trials.

I have used Consumable inapp purchase model.

but the problem is when the user installing the application for first time user have 4 trials available for free. if user used 2 trials then user have 2 trials remaining. and user uninstalled the application and installed application again from appstore.when the user installed new application user have 4 trials available instead of 2 trials because apple allow user to download application 10 times once user had purchased product once with the same Apple ID.

So Is there any way maintain the inapppurchase state by which i will prevent the user to access the trial more than 4 times ?

Thanks In advance
  