Welcome, Guest
Username Password: Remember me

STV 2.0b2: SCNumericTextFieldCell not working with Core Data entity
(1 viewing) (1) Guest
  • Page:
  • 1

TOPIC: STV 2.0b2: SCNumericTextFieldCell not working with Core Data entity

STV 2.0b2: SCNumericTextFieldCell not working with Core Data entity 1 year, 4 months ago #1

I have a Core Data based application that contains an entity with a property defined as a float. I've set the STV property type to SCPropertyTypeNumericTextField in the class definition and a SCNumericTextFieldCell is displayed in the detail view for this entity, but when the entity is saved, Core Data raises an NSInvalidArgumentException when calling [NSManagedObject setValue:forKey:]
 
*** Terminating app due to uncaught exception 'NSInvalidArgumentException',
reason: 'Unacceptable type of value for attribute: property = "diameterMm"; desired
type = NSNumber; given type = NSCFString; value = 2.'

 

The problem occurs because [SCNumericTextFieldCell commitChanges] calls [SCTextFieldCell commitChanges], which sets self.boundValue to self.textField.text (SCTableViewCell.m line 1674). It isn't clear to me if I can just comment out the call to [super commitChanges] at line 1770, though. Any ideas?
  • pegli
  • OFFLINE
  • Fresh Boarder
  • Posts: 1
  • Karma: 0

Re: STV 2.0b2: SCNumericTextFieldCell not working with Core Data entity 1 year, 4 months ago #2

Hi Paul,

This bug has been actually fixed in our STV 2.0 beta. I'll send you a copy right away, please confirm that it's working fine for you.
  • tarekskr
  • OFFLINE
  • Administrator
  • Posts: 2402
  • Karma: 72

Re: STV 2.0b2: SCNumericTextFieldCell not working with Core Data entity 1 year, 4 months ago #3

Hi Tarek,

I am having this exact same problem, running STV 2.0 Beta 2 (which is the most recent beta version that I have received back in mid-December). Is there a fix for this issue?

Thanks,
Matthew
  • skoota
  • OFFLINE
  • Expert Boarder
  • Posts: 89
  • Karma: 2

Re: STV 2.0b2: SCNumericTextFieldCell not working with Core Data entity 1 year, 4 months ago #4

Hi Tarek,

Thanks for sending me the latest beta. That fixed the problem

Best wishes,
Matthew
  • skoota
  • OFFLINE
  • Expert Boarder
  • Posts: 89
  • Karma: 2

Re: STV 2.0b2: SCNumericTextFieldCell not working with Core Data entity 1 year, 2 months ago #5

Hi Tarek!

I know the new release is very close by (sweet! ) but i was wondering if it was possible to get the latest beta since i have the same issue and this kinda hinder the automated test we are trying to do.

Thanks!
  • codebonbon
  • OFFLINE
  • Expert Boarder
  • Posts: 147
  • Karma: 7

Re: STV 2.0b2: SCNumericTextFieldCell not working with Core Data entity 1 year, 2 months ago #6

Would also appreciate copy of current beta.

Thanks,

Bill
  • bill
  • OFFLINE
  • Fresh Boarder
  • Posts: 9
  • Karma: 0
  • Page:
  • 1
Time to create page: 1.63 seconds