UIFileSharingEnabled has no effect
Asked Answered
U

1

5

I've added UIFileSharingEnabled to the .plist. Per suggestions, I have:

  • removed the app and redeployed it several times
  • attempted to disconnect after redeploying

I have not been able to get the app visible in the File Sharing section in iTunes. On another app, this works flawlessly. The app where it doesn't work has a bit exotic internals (an easily portable game; as such, it has its own mainloop, it doesn't have a main nib, ...). The app where it does work is pretty much standard deal. Also, testing was done on two different devices: it worked on iPod Touch 4 with iOS 4.2.1, but it didn't work on iPhone 3GS with iOS 4.2.1.

Since it's a bit difficult to isolate the problem (and I could probably spend several MORE hours isolating it), is there any other known requirement to get file sharing to work?

Unsubstantial answered 28/12, 2010 at 13:16 Comment(0)
U
17

CFBundleDisplayName is additionally required in the .plist. Why Apple elected to require this, I have no idea.

Unsubstantial answered 28/12, 2010 at 13:58 Comment(4)
Is the following OK? I'm having the same problems, and CFBundleDisplayName is set to <key>CFBundleDisplayName</key> and <string>${PRODUCT_NAME}</string>Bates
That looks about right. You may want to restore other keys from template's plist that you may have removed. I'm just guessing which may be important: CFBundleName: ${PRODUCT_NAME}, CFBundleIdentifier: com.hindarium.${PRODUCT_NAME:rfc1034identifier}. Also, try entering a concrete name instead of PRODUCT_NAME variable, and check your PRODUCT_NAME variable for correctness. Otherwise, I'm out of ideas; I stumbled upon the original solution accidentally.Sonometer
Not really difficult; Apple apparently just forgot to document which keys they require to exist in plist. Theoretically, you just have to add the UIFileSharingEnabled key into the plist and that's it. Unfortunately, when the feature depends on additional keys present in the default template, and it is not specified which keys exactly are needed, it can get a bit tricky.Sonometer
It started working once I removed the spaces from my CFBundleDisplayName.Unidirectional

© 2022 - 2024 — McMap. All rights reserved.