Using the iTableView2 library I am trying to catch a selection in the SelectedChanged event where the DetailText contains an asterisk. Like this....
The error that follows is this:
B4X:
Sub AirportList_SelectedChanged (SectionIndex As Int, Cell As TableCell)
Private AirportIATA As String = Cell.DetailText.ToString
If AirportIATA.Contains("*") Then Return 'Exit & do nothing
Results.Show(AirportIATA) 'Do more stuff
End Sub
The error that follows is this:
By trial & error I can isolate the exception to the 'AirportIATA.Contains("*")' line. However, the IDE never highlights that line as the line where the exception has occurred, instead other lines, often ones with no code on them are highlighted. What is going on?Application_Start
Application_Active
Error occurred on line: 209 (PopulateList)
Object was not initialized (NSAttributedString)
Stack Trace: (
CoreFoundation <redacted> + 252
libobjc.A.dylib objc_exception_throw + 56
CoreFoundation <redacted> + 0
World Airports -[B4IObjectWrapper object] + 152
World Airports -[B4IAttributedString ToString] + 36
CoreFoundation <redacted> + 144
CoreFoundation <redacted> + 284
World Airports +[B4I runDynamicMethod:method:throwErrorIfMissing:args:] + 1624
World Airports -[B4IShell runMethod:] + 448
World Airports -[B4IShell raiseEventImpl:method:args::] + 1640
World Airports -[B4IShellBI raiseEvent:eventarams:] + 1560
World Airports +[B4IObjectWrapper raiseEvent:::] + 300
World Airports -[B4ITableViewDelgate tableView:didSelectRowAtIndexPath:] + 360
UIKit <redacted> + 1356
UIKit <redacted> + 268
UIKit <redacted> + 296
UIKit <redacted> + 384
UIKit <redacted> + 132
CoreFoundation <redacted> + 32
CoreFoundation <redacted> + 412
CoreFoundation <redacted> + 1436
CoreFoundation CFRunLoopRunSpecific + 552
GraphicsServices GSEventRunModal + 100
UIKit UIApplicationMain + 236
World Airports main + 124
libdyld.dylib <redacted> + 4
)