It is not redirecting to the VC I want it to. It is not even registering the click. I tested this with a print statement. Here is the code. The function giving me the problem is the last one of the code
homeVC.swift code - https://developer.apple.com/forums/content/attachment/09167e0f-250b-4f3e-beb5-4afacda404c5
Post
Replies
Boosts
Views
Activity
I am wondering what tools are best for creating an app to see a friends AR avatar in 3D space. Such as frameworks, kits, and services.
Here is the error
Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'could not dequeue a view of kind: UICollectionElementKindCell with identifier Cell - must register a nib or a class for the identifier or connect a prototype cell in a storyboard'
** First throw call stack:
(0x18a2d6a48 0x189ffdfa4 0x18a1d8e88 0x18a60e654 0x18dbd41e0 0x18dbd43c8 0x104a0dea4 0x104a0e6a8 0x18dbc0e74 0x18dbc56f0 0x18dbc9fbc 0x18e7f217c 0x190d5a2c0 0x190d6043c 0x190d6b140 0x190cb3884 0x190cdd574 0x190cddf68 0x18a253e68 0x18a24ed54 0x18a24f320 0x18a24eadc 0x1941ef328 0x18e35c63c 0x104a08c84 0x18a0d8360)
libc++abi.dylib: terminating with uncaught exception of type NSException
This is the code for homeVC.swift (most is just parse backend so ignore)
homeVC.swift code - https://developer.apple.com/forums/content/attachment/412b7eae-0661-4be4-9e2f-4249be60456b
I am getting a SIGABRT. The breakpoint for the abort is
let cell = collectionView.dequeueReusableCell(withReuseIdentifier: "Cell", for: indexPath) as! pictureCell
I am trying to reference picture cell. This is the code for pictureCell.swift. It is a cell
import UIKit
class pictureCell: UICollectionViewCell {
@IBOutlet weak var picImg: UIImageView!
}
I have a tab bar controller that I am using as the home page for my app. I want the signup modal to close when the user presses sign up. here is the code.
		func login() {
				
				// remember user's login
				let username : String? = UserDefaults.standard.string(forKey: "username")
				
				// if loged in
				if username != nil {
						
						let storyboard : UIStoryboard = UIStoryboard(name: "Main", bundle: nil)
						let myTabBar = storyboard.instantiateViewController(withIdentifier: "tabBar") as! UITabBarController
						window?.rootViewController = myTabBar
				}
				
		}
I am using a MongoDB server on Heroku running Parse.The error comes when I push the Sign Up button to send the form to my server. I believe it has something to do with the connection to the server and not the json format as the error suggests.
func login() {
				
		// remember user's login
		let username : String? = UserDefaults.standard.string(forKey: "username")
				
		// if loged in
		if username != nil {
						
				var window: UIWindow?
				let storyboard : UIStoryboard = UIStoryboard(name: "Main", bundle: nil)
				let myTabBar = storyboard.instantiateViewController(withIdentifier: "tabBar") as! UITabBarController
				window?.rootViewController = myTabBar
		}
				
}
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
		// Override point for customization after application launch.
				var window: UIWindow?
				// accessing heroku app vi id & keys
				Parse.enableLocalDatastore()
				
				// Initialize Parse.
				Parse.setApplicationId("example", clientKey: "exmaple")
		
				// [Optional] Track statistics around application opens.
				PFAnalytics.trackAppOpened(launchOptions: launchOptions)
		
				// call login function
				login()
		
				// color of window
				window?.backgroundColor = .white
		
				return true
I am trying to use the "convertFromUIImagePickerControllerInfoKeyDictionary" and "convertFromUIImagePickerControllerInfoKey" identifiers in xcode 11.3.1. I am getting errors for unresolved identifiers for both.
This is the code
func imagePickerController(_ picker: UIImagePickerController, didFinishPickingMediaWithInfo info: [UIImagePickerController.InfoKey : Any]) {
				let info = convertFromUIImagePickerControllerInfoKeyDictionary(info)
				avaImg.image = info[convertFromUIImagePickerControllerInfoKey(UIImagePickerController.InfoKey.editedImage)] as? UIImage
				self.dismiss(animated: true, completion: nil)