Objective-C - how might I be able to create a objective-c coroutine? When I have a IBAction called by a button it freezes the app until the IBAction finishes retreiving data (from a web site). How might I have this run as a coroutine to the main app?
Thanks,
Christian Stewart
...
I was wondering, what (if any) is the difference between creating objects using:
NSThing *thing = [[NSThing alloc] initWithObject:object];
vs
NSThing *thing = [[NSThing thingWithObject:object] retain];
Is there a difference in how the memory management works? Also, when is it common practice to use one vs the other?
...
Hi all.
Maybe there is a simple solution to this, but I'm getting headache of this, I'm fairly new with all this Core Data stuff:
I have a BankAccount class/entity with an "index" attribute, used for sorting, and a "transactions" to-many relationship to the Transaction class/entity. This Transaction entity has a "date" attribute, that ...
I am using a standard navigator interface on the iPhone. When I move from the highest level tableview to the next level, I have to load about 2000 records from core data, which can take 5-10 seconds, so I want to use an activity indicator.
I have done the following code which works if I remove the code in the DidSelect method, but othe...
I have a root view and a detail view, in the detail view is a AVAudioPlayer with a basic play/pause button setup. All works, however if I play the file and then click back (popViewControllerAnimated) to the root, the file keeps playing which is correct, but then if I click back to the detail view the view has reset and doesn't find the i...
I am looking to create a simple colour palette, and have setup a grid of buttons in interface builder.
I'd like a user to be able to interact with the palette (buttons), by selecting any button, then drag the finger between buttons (firing events on entering and exiting a button and changing the selected colour with each event). Is thi...
I need to create two instances of two classes inside a view controller that stay alive for the entire time that view is open.
Inside theese one of theese classes I need to create a NSString and a NSDate that stays alive for the entire time the class is alive.
How do I do this?
...
Hello!
I am attempting to follow the tutorial shown here - http://www.iphonesdkarticles.com/2009/01/uitableview-sectioned-table-view.html - and implement it in my own code.
Here's the problem I'm getting -
data, wishlists, and wishlistids are all NSMutableArrays. I know this problem is occuring on the line where I try to add the dict...
I have an object that is appending a local string to another, and then handing that to an instance variable. This StringObj is being held by the calling UITableViewController. On the first call, fullCmdString has the string correctly. However, on 2nd call, the fullCmdString is null, or full of weird data (looks like data in odd mem locat...
I'm new to Objective C for iPhone. I tried the following code to get the screen size, however the code below returns two different result:
CGRect screenRect = [UIScreen mainScreen].bounds;
NSLog(@"width: %d", screenRect.size.width);
NSUInteger width = [UIScreen mainScreen].bounds.size.width;
NSUInteger height = [UIScreen mainScreen].bou...
Hi all,
I am implementing an application using MapKit.My question is like this, "Is it possible to call a method when the user taps on the accessory view of the pin in the map, instead of tapping on the accessory button?". Please suggest me on this.
Thanks in advance,
Sekhar Bethalam.
...
hi all,
i have 1 variable of type char[] and i want to copy nnstring value in it can anyone know how to convert nnstring to char array.
...
Hi Guys,
I am currently building an ebook tool. I have used UIViewView to load the content. Its working fine.
But the issue here is content loading time, each page takes 3 seconds to load and the content does not fits to page. Seems UIWebView has some memory issue too.
Should I use UIWebView to load pdf content or Should I take a new...
NSInteger timeNum = time;
NSMutableArray theResultArray = [[NSMutableArray alloc] init];
[theResultArray insertObject:[NSNumber numberWithInt:timeNum] atIndex:rightIndex];
This is the way we do to insert NSInteger to array. How to i do it for NSString?
...
Hi,
I want repeat on the Every Sunday and Monday
How can i achive this ??
plz help me
...
Hello,
I have an NSMutableArray which holds the dates in format dd/MM/yyyy of type NSString.
Now i need to display the sorted array of dates. Please suggest me how to achieve it.
Thank You.
...
I've got an array of NSNumber objects created thusly:
myArray = [[NSMutableArray alloc] initWithObjects:[NSNumber numberWithDouble:0.0],
[NSNumber numberWithDouble:0.0],
[NSNumber numberWithDouble:0.0],
[NSNumber numberWithDouble:0.0],
[NSNumber numberWithDouble:0.0...
Hi guys,
Can we upload both image and audio file at a time into Jsp server.If yes can any one please post the code for me how to do as I am newbie to the Iphone sdk.
Thanks in advance,
Monish.
...
I am using navigation based approach. In RootViewController, I got a detailViewController. I want to control detailViewController from RootViewController. I tried Something like that.
in RootViewController.h
@interface RootViewController : UITableViewController{
PlayerListView *detailViewController;
}
in RootViewController.m
- (v...
Hi! After App Store approvement my app started to crash on launch on 3.1.2 devices. Debug version installed from Xcode works fine on 3.1.2. Both debug and distribution version from App Store work fine on 3.2 and 4.0.1 devices. From crash log:
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x00000000, 0x00000000
Crashed Thread: 0...