Quantcast
Channel: Active questions tagged uipickerview - Stack Overflow
Viewing all articles
Browse latest Browse all 594

UIPickerView EXC_BAD_ACCESS crash

$
0
0

I'm getting a crash with a stack trace I don't understand.

Here is the stack trace:

Crashed: com.apple.main-threadEXC_BAD_ACCESS KERN_INVALID_ADDRESS 0x00000000000000000UIKitCore-[UISectionRowData heightForRow:inSection:canGuess:] + 488UIKitCore-[UIPickerView _selectRow:inComponent:animated:notify:] + 1609Force Patient - Line 4307182604PhaseViewController.viewDidLoad() + 430718260410Force Patient - Line 4307183832@objc PhaseViewController.viewDidLoad() + 4307183832

Here is the only code related to picker view in my viewDidLoad() method:

if #available(iOS 13.0, *) {    self.phasePickerView.overrideUserInterfaceStyle = .light}if self.selectedPhaseIndex != -1 {    // selecting phase from timeline    self.loadSelectedPrescriptions(row: self.selectedPhaseIndex)    self.phasePickerView.selectRow(self.selectedPhaseIndex, inComponent: 0, animated: false)} else {    // loading active phase    self.phasePickerView.selectRow(self.activePhaseIndex, inComponent: 0, animated: false)}

I guess I don't understand what EXC_BAD_ACCESS KERN_INVALID_ADDRESS means in this context.

All help appreciated.


Viewing all articles
Browse latest Browse all 594

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>