awakeFromNib and Mutable Array Questions
awakeFromNib and Mutable Array Questions
- Subject: awakeFromNib and Mutable Array Questions
- From: Sindhu Gururaj <email@hidden>
- Date: Mon, 14 Jul 2003 15:35:00 +0100 (BST)
Sorry, if there have been multiple postings, the mails
bounced back to me hence i am reposting the mail.
Hi All:
Thanks u all for the great response.
I am able to add my structure(s) to an NSMutableArray
which i want to use LATER.
Have some more questions though,
1]
typedef struct mystruct
{
char filename[10];
int fileDate;
int fileSize;
} myfileRecord;
// i am adding this struct to NSMutableArray as
follows.IS THIS CORRECT?
NSMutableArray* m_FileRecordArray;
m_FileRecordArray = [[NSMutableArray array] retain];
[m_FileRecordArray addObject:[NSValue
valueWithPointer:&FileRecordInfo]];
// where FileRecordInfo is my populated structure
which my current function is receiving,
now i want to query the array for an object at a
particular index and see the value stored in each of
these structure elements.
How is this done??
How do i access the structure which is wrapped in the
NSValue and see each of the structure elements at a
particular index??
2]How do i delete the structure stored at a particular
index.?
3] I have another question completly offtopic but
about cocoa,
Why does awakeFromNib function get called twice and
sometimes THRICE.
What is the funda? even after going through a lot of
documentation, i was not able to grasp much.
can anyone pls explain it in layman's words? Also can
we make it to be called only ONCE?
i am doing a lot of important functionality in it and
don't want it to be called twice.
I cannot call any Application Notifications as my
project is Cocoa FRAMEWORK.
Can anyone suggest an alternate functionality that can
be used instead of awakeFromNib.
Thanks in advance.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.