iphone

How to find a call is unanswered in iphone

Hi, If i make a call from an application using [[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"tel://1234567890"]]; How can i check if the call is answered or unanswered Thanks, ...

How does the UITableView get styled in the Core Data Recipes Sample code?

I'm trying to use Apple Core Data Sample code as a basis for my own app. I'm using this code: http://developer.apple.com/iphone/library/samplecode/iPhoneCoreDataRecipes/index.html I can't work out how that first table View is styled. I want it to be grouped (UITableViewStyleGrouped), but there seems to be no obvious place to tell it how...

implementation methods to interface xcode script

Hello, I would like to ask if somebody has some user script to copy all implementation methods definitions to the clipboard that can be pasted to the header definitions. ...

iPhone-SDK:How to set background color for View and not for the Table?

I have downloaded TableView sample code '4_TableViewCellSubviews' from internet. I am trying to run this program in my way. I am trying to set my own background view color as 'lightgraycolor'. I just wanted to see the background view as lightgraycolor in this application. I don't want to make any color for TableView. i.e i want to give g...

How can I determine a CLLocation or MKPlacemark from an address?

I've seen API documentation and demo after demo on how to do a reverse geocode - to get an address, given a Lat/Long location. I need to do the reverse. I'm assuming that this is already solved problem since Apple's MapKit API avoids it entirely. ...

Math logic (basic trig) in a game, what is this code doing?

I'm trying to better understand what exactly this code is doing. It's written in Objective-C, but should be familiar to anyone with a C background. What exactly are sin/cos mathematics doing here? Also, does anyone have a good recommendation for learning trig for gaming concepts such as these? for (int i = 0; i < GAME_CIRCLES; i++) { p...

Implementing "Add to Home Screen", ala Safari

Safari on iPhone has a feature that lets you create a shortcut on your home screen for a web page. Is it possible for other apps to implement similar functionality? I'd like to give my users a quick way to jump to a specific item in my iPhone application. ...

Transparent color works on the simulator but becomes black on the iPhone

Hi! I am trying to draw an image that has some transparent regions. I load the image using image = [UIImage imageNamed:@"testimage.png"]; and draw it using [image drawAtPoint:CGPointMake(0,0)]; The UIView on which I draw the image is not opaque (and it has a transparent background color). The problem is that everything works fin...

Auto rotation for 1 tab out of 5 tabs

I have 5 tabs in my app and 1 needs to be able to autorotate. So far I have been able to get all 5 tabs to rotate using: (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation { return YES; } However I only need 1 to rotate, How could I do this?? ...

Compiling non-source files in Xcode

I've got several file pairs: mydata.json, mydata.raw other.json, other.raw etc... A custom tool builds these files into data files to be consumed by my app, like so: mydata.dat, other.dat, etc... What is the correct way for me to set up Xcode to build these resource files? Either one could change, so I can't just set up a custom bui...

Why is Instruments reporting custom UITableViewCell code as a memory leak?

I'm still trying to find my way through memory management for the iPhone SDK, and I'm not sure why Instruments is reporting a certain block of code as a memory leak. I've followed tutorials for these parts of the code, so I'm not really sure what I'm doing wrong. The violating block of code: DreamTableCell *cell = (DreamTableCell *)[ta...

512x512 image for the iPhone app

I am about to submit my first app to the iTunes App Store. The docs say that the application needs to be submitted with a "512x512 px, 72ppi, RGB, flattened, no transparency JPEG image". I have a couple of questions: RGB - what exactly does it mean in this context. Flattened - does it mean that if I am creating the image in Photoshop...

iphone RESTful webservices

Not even sure if the title is correct, however, what I'm trying to do is use the standard NSURLConnection class to handle responses from calling my webservice. I am using the POST method to update a database and the GET method to retrieve rows from the database. The problem I have is that these 2 actions may occur simultaneously so tha...

UITableView crashes after trying to delete a cell the *second* time

Hi guys - another weird problem with the iPhone SDK here. I have a UITableView which contains a custom UITableViewCell. This table gets its data from a mutable array, which in turn pulls it from a Core Data storage. The problem: If I enter editing mode and delete a cell, it works for the first time - the cell is successfully removed fr...

Progamatic intialisation of reuseable TableViewController from a NavigationController

I'ld like to create a Navigation controller programatically from a Nib file, and add to that a table view controller (as its root controller). The table view controller needs to be initialised with a data set that can be changed. This is so I can reuse the table view controller in different two places (one from a list showing all data a...

disable rotation of a webpage in iphone

I'm developing a webapp for the iphone. I'd like to force a certain page to always show in landscape mode not rotate. Is there an easy way to do this? ...

Duplicate records in Core Data on fetch

Folks, I've got a bit of a puzzler involving Core Data in my iPhone project. During the viewDidLoad method in two separate view controller instances I call the following method: - (NSFetchedResultsController *)getStudentResults:(NSString *)classRoom forWeekStarting:(NSDate *)startDate andEnding:(NSDate *)endDate { AttendanceAppDel...

Automatically expand UITableView - NSRangeException

I have a SQLite database tied to my uitableview. There are about 2000 rows, so I retrieve 25 rows at first. Once I scroll to the end of the list, I want it to automatically retrieve 25 more rows. Here's the method I'm using now. Ignore what would happen if I load all 2000 rows, I'll worry about that later. In tableView:numberOfRowsInSe...

Weird error: wait_fences: failed to receive reply: 10004003

I know that there are other questions that deal with this error, but those answers don't help me any. I was wondering if anyone knew the exact cause, and if no one does, here is the code: -(void) imagePickerController : (UIImagePickerController *) picker didFinishPickingImage : (UIImage *) image editingInfo : (NSDictionary *) edit...

Suddenly I am not able to build for the iphone simulator...

Hi Everyone, Sometimes one wants to really hate the Apple development environment. Seriously, does it need to be this complicated? My problem is this. I am no longer able to build my project to the Simulator. I am getting the following errors. I realize it is a linker error - what I dont understand is 1) why this suddenly is no l...