store.loadProducts not returning anything/callback never triggered

Hi all,

I’m hoping someone can shed some light on an issue I’m having implementing IAPs, namely, store.loadProducts not returning anything (the callback/listener never executes). This is on iOS by the way.

The IAPs appear to be configured in iTunes Connect correctly, as both store.purchase and store.restore both work perfectly using test accounts also setup through iTunes Connect.

My code is structured similarly to the sample app, in that the store.loadProducts in wrapped in a store.canLoadProducts check, and followed by a print(“store.loadProducts called. Waiting for listener”) - or something very similar; I don’t have the code in front of me right now.

The print(“store.loadProducts called…”) executes so I know it has passed over the store.loadProducts line, and yet nothing actually happens - the listener never executes. I’ve also tried waiting a significant amount of time ( ~20 seconds - performWithDelay) after the call and just checking the productList table, in case loadProducts is returning but the callback doesn’t fire, however, productList is always nil.

I’d like to be able to retrieve and display the price of the IAP in the UI, which is the reason for the loadProducts call.

Has anyone come across this problem? 

Thanks!

Glenn

Forget it sorry; I didn’t realise you needed to pass it a pre-populated list of Product IDs. Problem solved.

productIdentifiers (required)

Array. A Lua array with each element containing a string which is the product identifier of the in-app item you want to know about.

Forget it sorry; I didn’t realise you needed to pass it a pre-populated list of Product IDs. Problem solved.

productIdentifiers (required)

Array. A Lua array with each element containing a string which is the product identifier of the in-app item you want to know about.