IOS Development Quick Fix
This blog will help developer to fix time consuming issues within a minute.
Monday, 14 October 2019
Wednesday, 19 September 2018
Tuesday, 18 September 2018
Wednesday, 7 February 2018
Find the index of object in array in swift 4
userList is array of objects [User]
userID is identity of object, which is use for find index.
let userID = "1"
let tempIndex = userList.index(where: { (user: User) -> Bool in
user.userID == userID
})
Filter array of objects in swift 4
userList is array of objects [User]
userID is identity of object, which is use for filter
See bellow method, In this method filtered the userList array by userID. get all users which are having same userID.
func filtered(userID: String) -> [User] {
if userList.count > 0{
let filteredArray = userList.filter { (obj) -> Bool in
obj.userID == userID
}
return filteredArray
}
return []
}
Unbalanced calls to begin/end appearance transitions for...
This type of error logs print when your presented view-controller is diapering while you trying to present another controller like..
- UIAlertView
- UIAlertController
- Present Model View Controller...etc.
Solution is within a second.
Keep remember above all type of controller present after the disappear presented controller successful.
- Set disappear delegate, in this callback you may present above types of controllers
- Add 0.5 second timer to present above types of controllers
Wednesday, 20 January 2016
This build is invalid on itunesconnect
Please follow bellow steps to encounter the issue.
- Upgrade latest OS X
- Use latest XCODE version
- Verify app icons in bundle or in Assets.xcassets. (mostly issue due to dose not added proper size of icons, even you missed any single icon then also getting this type error)
- Verify provisioning profile
- Use Latest Application Loader for submit package (ipa)
Happy coding!
Subscribe to:
Posts (Atom)