Question

I am creating an application with 3 different languages: english, spanish and french. I have created in-app purchases in these 3 languages and have created users on itunes sandbox for these 3 stores: France, USA and Spain.

Before the user can click on the BUY button, even before the user logs in with his itunes username and password, I have to retrieve the prices of each product. This retrieval is done at the beginning of the application using this lines:

SKProductsRequest *request= [[SKProductsRequest alloc] initWithProductIdentifiers:IDobjects];
request.delegate = self;
[request start];

In theory, this code should retrieve, among other things, the price of all objects in the local currency. By local currency I mean based on the language the user has its iPhone adjusted but in practice this code always retrieve the price in dollars?

What am I missing?

Another point is this: if the user is not logged in on iTunes, he/she will always see the message in English and the prices in dollars. After logging in, he will see the name of the in-app object in his language and the price in his currency, but the rest of the window will be in english. See next image:

alt text

thanks for any help.

Caixa is the object's name in spanish, 0,79€ is the correct price in local currency but the remainder of the window is in english!? This window should be totally in the user's language!!!!!

Was it helpful?

Solution 3

The problem vanished a few days ago. It appears it was something inside apple.

OTHER TIPS

Here's the code from the Apple Docs:

NSNumberFormatter *numberFormatter = [[NSNumberFormatter alloc] init];
[numberFormatter setFormatterBehavior:NSNumberFormatterBehavior10_4];
[numberFormatter setNumberStyle:NSNumberFormatterCurrencyStyle];
[numberFormatter setLocale:product.priceLocale];
NSString *formattedString = [numberFormatter stringFromNumber:product.price];

How about using localized strings? So instead of @"Do you want to buy...", you would have something like: kPurchasePromptMessage, which will return a different string depending on the language used on the iphone.

For That:

  1. You have add Languages in Manage in-app purchase management for each bundleid
  2. create test user For that country.
  3. test your in-app purchase in application
  4. enter your new test user for that country
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top