Hello All, I am looking for the best way to turn a feature off after 7 days. Basically I am offering them the product for 7 days and then cutting it off and asking them to buy it. All input welcomed. Thanks [import]uid: 34105 topic_id: 31788 reply_id: 331788[/import]
Store the firstrun date/time in a file. Check that date and see if 7 days have elapsed. If they delete and re-install the app however, it will defeat this scheme.
The foolproof way is to store the date on a server somewhere on the internet and check that date, but that’s potentially defeatable by airplane mode, if you want your app to work off line.
However a combination of the two should work. On first run, it has to contact your server, and after that it can check the local date. If there is no local saved date, then contact the server again.
[import]uid: 19626 topic_id: 31788 reply_id: 126916[/import]
Thanks for the input Rob, I will see what I can do to implement what you recommended. This is the last step for my app. [import]uid: 34105 topic_id: 31788 reply_id: 126923[/import]
What app stores are you submitting this to?
You may run into trouble with some of them and get your app rejected or pulled from the store after release. Have you seen any other apps that implement something like this? [import]uid: 67839 topic_id: 31788 reply_id: 126956[/import]
you are absolutly right. the better way is to offer all function for 7 days and then reduce the function to a lite version until the user has purchased the app. don’t forget to programm a restore function for thoose user who must download the app again or on another device… see restore function of the app store if you working for ios…
[import]uid: 96270 topic_id: 31788 reply_id: 126974[/import]
Store the firstrun date/time in a file. Check that date and see if 7 days have elapsed. If they delete and re-install the app however, it will defeat this scheme.
The foolproof way is to store the date on a server somewhere on the internet and check that date, but that’s potentially defeatable by airplane mode, if you want your app to work off line.
However a combination of the two should work. On first run, it has to contact your server, and after that it can check the local date. If there is no local saved date, then contact the server again.
[import]uid: 19626 topic_id: 31788 reply_id: 126916[/import]
Thanks for the input Rob, I will see what I can do to implement what you recommended. This is the last step for my app. [import]uid: 34105 topic_id: 31788 reply_id: 126923[/import]
What app stores are you submitting this to?
You may run into trouble with some of them and get your app rejected or pulled from the store after release. Have you seen any other apps that implement something like this? [import]uid: 67839 topic_id: 31788 reply_id: 126956[/import]
you are absolutly right. the better way is to offer all function for 7 days and then reduce the function to a lite version until the user has purchased the app. don’t forget to programm a restore function for thoose user who must download the app again or on another device… see restore function of the app store if you working for ios…
[import]uid: 96270 topic_id: 31788 reply_id: 126974[/import]
@elbowroomapps I am using the Apple store. I may have confused everyone with my original post. The situation is that My app has seven day subscriptions. I have it so when they purchase the subscription for 7 days it will change the number in a file from 0 to 1 and from that it will change my button to a different frame. I am trying to figure out how to change that 1 back to a 0 after 7 days so the app button goes back to frame 1 to ask the customer to subscribe again. Or is this even possible. Code below
[code]
local footballBtn = function (event)
local footballBtn = movieclip.newAnim({“buy.png”,“gobtn.png”}, 80, 36)
footballBtn.x = 265; footballBtn.y = 121
screenGroup:insert( footballBtn )
local onBuyfootballTouch = function( event )
if event.phase == “ended” and footballbuy ~= 1 then
audio.play( tapSound )
storyboard.gotoScene( “loader2”, “fade”, 300 )
local buyfootball = function ( product )
print ("Congrats! Purchasing " …product)
– Purchase the item
if store.canMakePurchases then
print(“at store.can make purchases”)
store.purchase( {validProducts[1]} )
else
native.showAlert(“Store purchases are not available, please try again later”, { “OK” } )
end
end
– Enter your product ID here
buyfootball(“domain.app.football”)
elseif event.phase == “ended” and footballbuy == 1 then
audio.play( tapSound )
print(“Go Button”)
storyboard.gotoScene( “football”, “fade”, 300 )
end
end
footballBtn:addEventListener( “touch”, onBuyfootballTouch )
if footballbuy == 1 then
footballBtn:stopAtFrame(2)
print(“Go Button”)
end
if footballbuy == 1 then
footballBtn:stopAtFrame(2)
print(“Go Button2”)
end
end
timer.performWithDelay( 1000, footballBtn , 1 )
[/code] [import]uid: 34105 topic_id: 31788 reply_id: 127196[/import]
@elbowroomapps I am using the Apple store. I may have confused everyone with my original post. The situation is that My app has seven day subscriptions. I have it so when they purchase the subscription for 7 days it will change the number in a file from 0 to 1 and from that it will change my button to a different frame. I am trying to figure out how to change that 1 back to a 0 after 7 days so the app button goes back to frame 1 to ask the customer to subscribe again. Or is this even possible. Code below
[code]
local footballBtn = function (event)
local footballBtn = movieclip.newAnim({“buy.png”,“gobtn.png”}, 80, 36)
footballBtn.x = 265; footballBtn.y = 121
screenGroup:insert( footballBtn )
local onBuyfootballTouch = function( event )
if event.phase == “ended” and footballbuy ~= 1 then
audio.play( tapSound )
storyboard.gotoScene( “loader2”, “fade”, 300 )
local buyfootball = function ( product )
print ("Congrats! Purchasing " …product)
– Purchase the item
if store.canMakePurchases then
print(“at store.can make purchases”)
store.purchase( {validProducts[1]} )
else
native.showAlert(“Store purchases are not available, please try again later”, { “OK” } )
end
end
– Enter your product ID here
buyfootball(“domain.app.football”)
elseif event.phase == “ended” and footballbuy == 1 then
audio.play( tapSound )
print(“Go Button”)
storyboard.gotoScene( “football”, “fade”, 300 )
end
end
footballBtn:addEventListener( “touch”, onBuyfootballTouch )
if footballbuy == 1 then
footballBtn:stopAtFrame(2)
print(“Go Button”)
end
if footballbuy == 1 then
footballBtn:stopAtFrame(2)
print(“Go Button2”)
end
end
timer.performWithDelay( 1000, footballBtn , 1 )
[/code] [import]uid: 34105 topic_id: 31788 reply_id: 127196[/import]