How to use iOS device settings for language in Ionic 5 / Cordova

How do set language for context menus (select all, cut, copy, paste…), file upload, camera dialogues and other iOS or plugin functionality that is outside of your core project?

The answer is CFBundleDevelopmentRegion set in info.plist

It seems CFBundleDevelopmentRegion is always set to en_US by default (or maybe this is because I build on a laptop that has these settings) thus showing context menus, file upload dialog etc in English.

I found that setting CFBundleDevelopmentRegion to empty uses device settings for language.

It seems making the change directly in Xcode does not work for some reason.

Put this in your config.xml ios section.

<platform name="ios">
   <config-file parent="CFBundleDevelopmentRegion" target="*-Info.plist">
            <string />

Note that some plugins seem to set language, so if you cannot get this to work, check your plugins. This was tested in Ionic 5 / Angular / Cordova.

Thanks to Maximillion Bartango on SO for putting me on the right track.

Please comment if this worked for you or if you have problems or other solutions.

Instruction for Apple App Store upload (from an App Developer to Client)

This is a blog post I wrote at my company web site (mobile app development)

It is aimed for our customers, who are mainly non-developers, on the steps for first time setup Apple Developer and App Store Connect for us to be able to sign and upload apps that we have developed for them. But it should be usable for any non-developer or developer in that same situation.

Ionic Cordova Error – ENOENT: no such file or directory

When trying to build (“ionic cordova build ios”) my Ionic Cordova project, I got this error: “Error: ENOENT: no such file or directory“.

Took me awhile to figure out since I had just copied the project from an older project, made a few changes etc. Turns out the cause was that I had used a slash (“/”) in the app name in config.xml, changing the name fixed the issue.

[code]Copying iOS template project to /xxx/platforms/ios
shell.js: internal error
Error: ENOENT: no such file or directory, rename ‘/xxx/platforms/ios/__TEMP__.xcodeproj’ -> ‘/xxx/platforms/ios/project/name.xcodeproj’
at Object.renameSync (fs.js:594:3)
at /xxx/node_modules/cordova-ios/node_modules/shelljs/src/mv.js:77:8
at Array.forEach (<anonymous>)
at Object._mv (/xxx/node_modules/cordova-ios/node_modules/shelljs/src/mv.js:53:11)
at (/xxx/node_modules/cordova-ios/node_modules/shelljs/src/common.js:186:23)
at copyTemplateFiles (/xxx/node_modules/cordova-ios/bin/lib/create.js:124:11)
at Object.exports.createProject (/xxx/node_modules/cordova-ios/bin/lib/create.js:228:5)
at Api.createPlatform (/xxx/node_modules/cordova-ios/bin/templates/scripts/cordova/Api.js:122:14)
at /usr/local/lib/node_modules/cordova/node_modules/cordova-lib/src/cordova/platform/addHelper.js:188:28
at _fulfilled (/usr/local/lib/node_modules/cordova/node_modules/q/q.js:854:54
[ERROR] An error occurred while running subprocess cordova.
cordova platform add ios –verbose –save exited with exit code 1.
Re-running this command with the –verbose flag may provide more information. [/code]

Xcode and Bitbucket gives Authentication Failed

When cloning a Bitbucket repository from Xcode (using current version 9.2) I get Authentication failed.

Solution is to insert Password into URL.


  1. Copy repository URL from Bitbucket – Overview, select HTTPS (not SSH)
  2. Paste it in to Xcode Clone window for Adding GitHub account (for example click “Clone an existing Project” from Xcode start screen)
  3. Before clicking the Clone button, edit the url to insert your Bitbucket password.
    Url looks something like this:
    https://[email protected]/xxx/yourproject.git
    Add password like this, colon and your password:
  4. Click Clone button and it should work

Solved: Email not received and no NDR on Office365 Microsoft online

I recently had the problem where a person sent me a zipped file from his gmail account to my email account at Microsoft online/Office365. The email never reached me and the sender never received any NDR (Non Delivery Report). So I thought he hadn’t sent me anything while he was sure I had received it. Luckily in this case, I was expecting an email from him so I got in touch and we could start troubleshooting. How many other emails like this I have not received since I started using Microsoft online years ago, I will never know.

After some troubleshooting including going into Office 365 Admin – Exchange Admin Center – Mail Flow -Message Trace I found the messages and could see that the zip file had incorrectly been deemed as malware. Messages were marked as deleted and not delivered. I opened a support ticket with Microsoft and found out that the default setting in Microsoft online is to just delete emails with suspected malware without notifying anyone about it.

In my opinion this is not the smartest default setting but fortunately you can change it:

  1. Sign in as admin to Office365 Admin at
  2. Go to Exchange Admin Center
  3. Go to Protection – Malware filter
  4. If you have not made changes to the Malware filter before you probably only have one Malware filter rule: Default. Doubleclick it to edit.
  5. Under Settings + Malware Detection Response, I changed from “Delete the entire message” to “Delete all attachments and use default alert text”, this means you as a recipient will receive the msg but without the suspected malware.
    There are also other settings you can change such as Sender Notifications and Administrator Notifications if you lso or instead want the Sender or Admin to be notified.

I hope this helps someone else out!


Set separator delimiter in CSV file to open correctly in Excel


I made a PHP script to export a SQL query (from MySql) to a CSV file for opening in Excel. I cannot control how different users have their Excel setup, ie what separator delimiter they have set (this differs with language settings or user may have changed setting)

So the field separator delimiter gave me some problems, ie Excel would not automatically open file columns correctly but put each row in a single cell, unless you use Import data to make it work.

Some forums suggested setting the separator delimiter in the csv file (delimiter is third argument for fputcsv) to tab (\t) but that did not help.

Solution (use csv header sep=)

Then I stumbled upon the possibility to add a parameter as a header to the actual csv file, simply add sep=<delimiter> to the beginning of your csv file and Excel will parse it. So for separator delimiter use comma (,), pipe (|), tab (\t) or whatever you set in your php code.

However I found a few caveats:

  • “sep=\t” needs to be in quotes (otherwise it will use header but also for some reason also show it as data in the spreadsheet and put it in its own cell and move all other cells on that row one position to the right)
  • You need to add newline \n after the sep= header (otherwise it will use header but also show it as data concatenated with first cells data)
  • Use fwrite as fputcsv will not work

Example to use tab as separator:

[code]fwrite($fp, "\"sep=\t\"\n");[/code]


I could not find much info on the subject of csv headers but this is the full thread that lead me on the to it (thanks Burhan Ali)

Tested with Excel 2016 on Windows 10 and Excel for Mac (15.25) on OSX El Capitan (10.11.15).

I have not tested on other spreadsheets software like OpenOffice, LibreOffice etc, so please share in the comments if you have any success with this.

Solution: USB Memory stick not showing in File explorer


I have some USB Flash Memory drives that I had used on a non-Windows system (ie a TV) so it is using another file system than Windows’ NTFS, FAT or FAT32. When I insert them into my Windows 10 laptop they are connected, ie they are found by Windows and show up under “Safely Remove Hardware and Eject Media” and in the Device Manager. But they are not assigned a drive letter and do not show up as a drive in the File Explorer (aka My Computer in earlier Windows versions) or command prompt.

At first, I just thought that the USB Memory stick was not working but after having the same problem with several USB Memories I realized it probably had something to do with the format on them. I tried to download the HP USB Disk Storage Format Tool, but the USB drive did not show up there either.

So how can I reformat the USB memory stick if it does not show up in the Windows File Explorer?


I found a solution that works for me from Mosely5165.

WARNING: Make sure you know what you’re doing before trying this. If you select the wrong disk you may loose your data or entire system.

1. Open a Windows Command Prompt as Administrator


2. Run Diskpart


This should launch Diskpart and give you the DISKPART> prompt.

3. List available disks

[code]list disk[/code]

4. From the list of disks select the one that is your USB drive, make sure to identify the right one.
WARNING: If you select the wrong disk you may loose your data or entire system

[code]select disk x[/code]

5. Create a primary partition

[code]create partition primary[/code]

If this gives you an error saying there is not enough space, give the Clean command, then try to create the partition again.

create partition primary[/code]

6. Give the following commands.

select partition 1
format fs=ntfs quick

Full thread can be found at Tom’s Hardware here.

Windows cannot connect to iPhone Personal Hotspot

I have ran into this a few times so I thougt I’d write down the solution as I seem to keep forgetting it. There are probably tons of other problems you can have with iPhone Personal Hotspot and Windows Wifi but this is the solution to one I keep running into.


I turn on the Personal Hotspot on my iPhone and it shows up fine as an available Wifi network in Windows only the Wifi name looks a little off in Windows compared to the iPhone. My iPhone name is “Max’s iPhone” but in Windows the apostrophe looks “scrambled” and is replaced by two “trash” characters, something like this: “Max¿Ǝ iPhone”.

When I try to connect my Windows laptop over Wifi it just keeps trying to connect – showing message “Checking network requirements” – before I finally get “Can’t connect to this network“. On the iPhone I get the blue Personal Hotspot field on top of the screen flashing on and off while Windows tries to connect.


Solution is to change the name of your iPhone to remove or replace the apostrophe.

To change name of your iPhone in iOS: Settings – General – About – Name

More info

I just fixed this and unfortunately cannot recreate or remember exact what the scrambled or trash characters in my iPhone name looked like but I think one of the characters was an upside down letter E and/or question mark. So it looks something like this “Max¿Ǝ iPhone”.

So this seems to be what messes things up for Windows.

For me it has worked both to remove the apostrophe or replace it, ie delete it and then type it again. The name will look the same in your iPhone but after this it will also look ok in Windows Wifi selection and Windows should be able to connect to your iPhone Personal Hotspot without any problem.

It seems this problem keeps reoccuring for me. I do not use Personal Hotspot that often so I’m not sure when or why this reoccurence happens but my best guess is that an iOS upgrade or switching to a new device and installing from backup may be the cause.

Currently running iOS 9.0.2 on an iPhone 6 and Windows 10 but I have had this problem in previous versions of both iOS and Windows.

Did this solution work for you?

Please let me and others know by commenting, provide what version of Windows and iOS you are using if you know it.

Windows 10 international support lacking

I have noticed a couple of things where Windows 10 does not support international the way I would expect a 2015 operating system to do. I have not found any solutions yet so any more info on these issues would be appreciated.

Compressed (zipped) folder

I tried to zip a folder in Windows 10 by right clicking and then selecting Send to – Compressed (zipped) folder but got this error:

[code]xxx cannot be compressed because it includes characters that cannot be used in a compressed folder, such as ". You should rename this file or directory. [/code]

The folder contains files with Swedish characters åäö in it. I cannot remember having any problems with this in Windows 7?


The calculator (calc.exe) only accepts the period sign (.) as decimal delimiter. In Sweden we have comma (,) as decimal delimiter and this has always worked in all Windows programs for as long as I can remember. Of course any properly written Windows app would know to take such settings from Windows regional settings but apparently the decimal separator is hardcoded in the Windows 10 version of the calculator.