Skip to content
This repository has been archived by the owner on May 1, 2024. It is now read-only.

Ch19/ConditionalCells/ConditionalCells.iOS: crash when switch "Is Programmer" to ON #13

Open
baskren opened this issue Aug 13, 2015 · 0 comments

Comments

@baskren
Copy link

baskren commented Aug 13, 2015

Environment:

  • MacOSX 10.10.4
  • Xamarin Studio 5.9.4 (build 5)
  • Xamarin.Forms.1.4.4.6392\build\portable-win+net45+wp80+win81+wpa81+MonoAndroid10+MonoTouch10+Xamarin.iOS10
  • iOS Simulator: iPhone 4s iOS 8.4 (Simulator Version 8.4 (SimulatorApp-565.9 CoreSimulator-117.15))
  • XCode: Version 6.4 (6E35b)

Steps to replicate:

  • Use source code "as is" from GitHub repository.
  • Run (using Debug | iPhone Simulator) using Xamarin Studio and the above environment
  • When app launches, tap on the switch in the "Are you a programmer?" cell

Expect to see:

  • Switch changes to "ON" and the "Platform" and "Language" cells are enabled

What happens:
App crashes with the following:

  • Message: Object reference not set to an instance of an object
  • Source: Xamarin.Forms.Platform.iOS
  • StackTrace:
  at Xamarin.Forms.Platform.iOS.ViewCellRenderer.UpdateIsEnabled (Xamarin.Forms.Platform.iOS.ViewTableCell cell, Xamarin.Forms.ViewCell viewCell) [0x00007] in <filename unknown>:0 
  at Xamarin.Forms.Platform.iOS.ViewCellRenderer.ViewCellPropertyChanged (System.Object sender, System.ComponentModel.PropertyChangedEventArgs e) [0x0002a] in <filename unknown>:0 
  at (wrapper delegate-invoke) <Module>:invoke_void_object_PropertyChangedEventArgs (object,System.ComponentModel.PropertyChangedEventArgs)
  at (wrapper delegate-invoke) <Module>:invoke_void_object_PropertyChangedEventArgs (object,System.ComponentModel.PropertyChangedEventArgs)
  at (wrapper delegate-invoke) <Module>:invoke_void_object_PropertyChangedEventArgs (object,System.ComponentModel.PropertyChangedEventArgs)
  at (wrapper delegate-invoke) <Module>:invoke_void_object_PropertyChangedEventArgs (object,System.ComponentModel.PropertyChangedEventArgs)
  at Xamarin.Forms.BindableObject.OnPropertyChanged (System.String propertyName) [0x00012] in <filename unknown>:0 
  at Xamarin.Forms.BindableObject.SetValueActual (Xamarin.Forms.BindableProperty property, Xamarin.Forms.BindablePropertyContext context, System.Object value, Boolean currentlyApplying, SetValueFlags attributes, Boolean silent) [0x000ff] in <filename unknown>:0 
  at Xamarin.Forms.BindableObject.SetValueCore (Xamarin.Forms.BindableProperty property, System.Object value, SetValueFlags attributes, SetValuePrivateFlags privateAttributes) [0x00235] in <filename unknown>:0 
  at Xamarin.Forms.BindableObject.SetValueCore (Xamarin.Forms.BindableProperty property, System.Object value, SetValueFlags attributes) [0x00000] in <filename unknown>:0 
  at Xamarin.Forms.BindingExpression.ApplyCore (System.Object sourceObject, Xamarin.Forms.BindableObject target, Xamarin.Forms.BindableProperty property, Boolean fromTarget) [0x001e2] in <filename unknown>:0 
  at Xamarin.Forms.BindingExpression.Apply (Boolean fromTarget) [0x00037] in <filename unknown>:0 
  at Xamarin.Forms.BindingExpression+BindingExpressionPart.<PropertyChanged>b__c () [0x00000] in <filename unknown>:0 
  at Foundation.NSAsyncActionDispatcher.Apply () [0x00000] in /Users/builder/data/lanes/1962/8b265d64/source/maccore/src/Foundation/NSAction.cs:164 
  at (wrapper managed-to-native) UIKit.UIApplication:UIApplicationMain (int,string[],intptr,intptr)
  at UIKit.UIApplication.Main (System.String[] args, IntPtr principal, IntPtr delegate) [0x00005] in /Users/builder/data/lanes/1962/8b265d64/source/maccore/src/UIKit/UIApplication.cs:63 
  at UIKit.UIApplication.Main (System.String[] args, System.String principalClassName, System.String delegateClassName) [0x00038] in /Users/builder/data/lanes/1962/8b265d64/source/maccore/src/UIKit/UIApplication.cs:47 
  at ConditionalCells.iOS.Application.Main (System.String[] args) [0x00008] in /Users/ben/Downloads/xamarin-forms-book-preview-2-master/Chapter19/ConditionalCells/ConditionalCells/ConditionalCells.iOS/Main.cs:17 
  • TargetSite: {Void UpdateIsEnabled(ViewTableCell, Xamarin.Forms.ViewCell)}
  • DeclaringType: {Xamarin.Forms.Platform.iOS.ViewCellRenderer}

Notes:

  • Switch does work on the Android version
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant