Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: converting object to another class



Thanks a lot for the quick reply!

cheers and Best Regards Christian

Am 21.09.2004 um 14:27 schrieb Ute Hoffmann:

Hi,
try setApeople((APeople)apeopleList.objectAtIndex(0));

You have to Typecast your Array object into the right type. Sio if you have a Class of type Apeople, and Apeople is of this class type you have to tell Java, that the element in the Array will be of the same type.

Don't know what to do if you have not created Java classes for your entities and you work with EO Generic records.

Hop that helps,

Regards

Ute

Am Dienstag, 21.09.04 um 13:54 Uhr schrieb Christian Telepski:

Hi,

i have some strange problems and i think it should be easy solved.
I have an entity of "apeople" in the database and an NSMutableArray wich stores all those "apeople".
This is "apeopleList".


Now i wanted to pass "apeopleList.objectAtIndex(0)" to the "apeople" with "setApeople(apeopleList.objectAtIndex(0))" but this does not > work!

The error is: "setApeople(apeople) cannot be applied to (java.lang.Object)"

How can i manage it?

Thanks in advance!

cheers Christian telepski

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/ email@hidden


This email sent to email@hidden



_______________________________________________ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/webobjects-dev/email@hidden

This email sent to email@hidden


Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.