BreezeCourier
Apple Fan
Profile
Posts: 30
Reg: Jun 21, 2012
Taylorville, IL
5,200
09/28/17 05:06 PM (7 years ago)

Update app to work with iOS 11

Help! I built my app back in late 2012 and haven't had to recompile since uploading to the app store...until now. We are getting the message that the app will no longer work once users update to iOS 11, which we expect they are doing pretty promptly. I'm using a several Custom URL screens, Menu Simple, Splash Screen, and some PDF Doc's. Nothing fancy at all. I assumed I would just need to export it again and recompile for iOS. I've exported and have it open in Xcode Version 8.3.3 but i'm getting 138 warnings about deprecations and i can't seem to get it to function in the simulator. I'm just getting a black screen. The app actively functions on my iPhone 7+ with iOS 10.3.3, but i do get warnings that it may cause slowness and won't work with iOS 11. The simulator i'm using is iPhone 7 Plus (10.1). What can I do to get this cleaned up, working and resubmitted quickly?
 
SmugWimp
Smugger than thou...
Profile
Posts: 6316
Reg: Nov 07, 2012
Tamuning, GU
81,410
like
09/29/17 09:14 PM (7 years ago)
While waiting for the official release, I wrote up some notes that might help: https://www.marianasgps.com/public/BTv3_to_iOS10.pdf (I'm working with Hostgator to get my SSL Cert renewed. If it barks at you, just accept the fact that I'm slow, and move on...) I've gotten feedback about the 'UIAlert Controller Code'. It didn't paste well in the PDF. So if you want detail on that, check out https://pastebin.com/9dmT5gqb Note the new method "clickedOnButton" because there is no more 'tag' for the Alert... this is sort of a workaround that I use. That should get rid of almost all of the issues, except for Downloads. That's tricky. I need to sit down, but I just haven't had time to figure it all out yet. In the interim, on a 'case by case' basis, you can get things downloaded if you modify this code: https://pastebin.com/dAzuNb4K And the best of luck to you! Cheers! -- Smug Edit: I would mention that sometimes, or a lot of times, this code is 'close', but not exact. It depends on the situation. Don't select and replace your code. Comment it out, leaving the original code legible, So that if an error occurs you can see what the original code intended to do, and modify the new code accordingly. And that BT link is valid, but the PDF doesn't select the entire URL. It should be: http://www.buzztouch.com/forum/thread.php?tid=17197693FE0F18530A39FE8
 
BreezeCourier
Apple Fan
Profile
Posts: 30
Reg: Jun 21, 2012
Taylorville, IL
5,200
like
10/02/17 05:01 PM (7 years ago)
Gah. Thanks for the response, SmugWimp! Truly appreciated! Unfortunately, i'm not skilled at all with this and i'm struggling to make these fixes. Most of my issues are in the following categories: UIAlertView, UIActionSheet, stringByAddingPercentEscapesUsingEncoding, initWithRequest:delegate:, etc. Are these not thing that are being adjusted to export correctly? I'm under deadline to get this updated and back out to the public. Any thoughts?
 
SmugWimp
Smugger than thou...
Profile
Posts: 6316
Reg: Nov 07, 2012
Tamuning, GU
81,410
like
10/02/17 08:04 PM (7 years ago)
All I can say is, we're waiting on an update. "Most" of the fixes are pretty generic, but a few of them aren't that simple. Don't delete the old code. Comment it out. The AlertView is pretty easy; just replace it with the UIAlertController. Your button doesn't have to do anything. (https://pastebin.com/34QnPGCE) The UIActionSheet requires a lot more care and feeding. The 'tag' value no longer exists, so any code you use, is sort of a combo of existing code, and code that resides in the action sheet 'clicked button at index' method... It ain't impossible, but it can be tedious. If you look at the 'clickedButtonAtIndex' method for whichever Action Sheet, you can see that the format is usually 'detect whether it was a yes/no, and then deal with the tag'. So what I end up doing is disregarding the whole 'yes/no' part, and focus on dealing with the 'tag' actions. That is done through the 'clickedOnButton' method. It requires a bit of comprehension, but it can be achieved. I've found that stringByAddingPercentEscapesBlahBlahBlah work easiest by just finding them all, and replacing only a portion of the line... "stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet URLFragmentAllowedCharacterSet]" (without the quotes, of course). You see the method in a bunch of different areas, with a bunch of different values, but it all comes down to replacing the 'inner' method with that. I know that keeping this stuff up to date is an arduous task, and I don't envy Kristen, Dave, and crew one bit. I wish they'd communicate a little more, but that's my thing. It's kind of like that old T-shirt said... "Just when you think you're ahead of the Rat Race, along come faster rats..." Cheers! -- Smug
 
BreezeCourier
Apple Fan
Profile
Posts: 30
Reg: Jun 21, 2012
Taylorville, IL
5,200
like
10/03/17 04:52 PM (7 years ago)
Thanks for the extra details! I've emailed David asking for a timeline on when this will be updated. We came here and have been working with this product, and now paying the monthly fee, because we didn't have the knowledge and expertise in order to do this ourselves and now we're between a rock and a hard place about what to tell our customers. I'm going to send you an email with some questions and an offer, hope you don't mind!
 
BreezeCourier
Apple Fan
Profile
Posts: 30
Reg: Jun 21, 2012
Taylorville, IL
5,200
like
10/08/17 10:05 AM (7 years ago)
Did you get my email?
 
SmugWimp
Smugger than thou...
Profile
Posts: 6316
Reg: Nov 07, 2012
Tamuning, GU
81,410
like
10/09/17 03:19 PM (7 years ago)
Not that I know of. I don't mind answering questions; usually I'm happy to do that on the forums. I'm not much of a gun for hire; I have enough going on locally. Cheers! -- Smug
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.