• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: CoreData validation question
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: CoreData validation question


  • Subject: Re: CoreData validation question
  • From: Arnold Nefkens <email@hidden>
  • Date: Mon, 26 Apr 2010 15:12:36 +0200

Thanks,

That was just what I needed..... It now works... Thanks again... Sometimes I am a bit lost. Started with iPhone development & Obj-C less then three months ago....
On 26 apr 2010, at 14:15, Steve Bird wrote:

>
> On Apr 26, 2010, at 7:51 AM, Arnold Nefkens wrote:
>
>> Hello list,
>>
>> I have the following validation method, why is it not working?
>>
>> -(BOOL)validateNumberField2:(id *)ioValue error:(NSError **)outError
>> {
>> 	NSNumber *inputNumberField2 = *ioValue;
>> 	NSNumber *numberField2Stat = self.numberField2;
>> 	NSNumber *numberField1Stat = self.numberField1;
>>
>> 	if (numberField2Stat != 0) {
>
> QUESTION:  What data type is "numberField2Stat" ?
> ANSWER: it's a POINTER to an NSNumber (not a numeric value).
> therefore it's very likely to never be zero.
>
>> 		if (inputNumberField2 <= numberField1Stat) {
>
> QUESTION:  What data type is "numberField1Stat" ?
> ANSWER: it's a POINTER to an NSNumber (not a numeric value).
> therefore ...... _____ ?
>
> consider using the intValue of your NSNumbers.
>
> ----------------------------------------------------------------
> Steve Bird
> Culverson Software - Elegant software that is a pleasure to use.
> www.Culverson.com                     (toll free) 1-877-676-8175
>
>

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >CoreData validation question (From: Arnold Nefkens <email@hidden>)
 >Re: CoreData validation question (From: Steve Bird <email@hidden>)

  • Prev by Date: Re: Creating temporary NSManagedObjects (PS)
  • Next by Date: Re: XCode 3.2.2 Hangs after Clean All but Previous Version Doesn't
  • Previous by thread: Re: CoreData validation question
  • Next by thread: Can't drag a custom data object.
  • Index(es):
    • Date
    • Thread