iphone

objective-c getters/setters & variable/property declarations--an easier way?

hopefully this is an easy one. I'm coding in objective-c and i'm wondering if there are any tools/tricks (anything) that you use for this annoyance (see below). Is there an easier way to declare variable/properties within the header and implementation files? e.g., I'm not a big fan of typing this in the header: NSString *commercial...

Creating multiple NSURLConnections. How to identify which Async call

I am intending to create 2 requests using NSURLConnection. When the server responds and calls connectionDidFinishLoading it passes in the connection as the parameter, but how do I identify which connection is passed in? ...

NSMutableURLRequest and a Password with special Characters won't work

I'm writing a small program (using Cocoa Touch), which communicates with a webservice. The code for calling the webservice, is the following: - (IBAction)send:(id)sender { if ([number.text length] > 0) { [[UIApplication sharedApplication] beginIgnoringInteractionEvents]; [activityIndicator startAnimating]; NSStr...

sending request to apple - from iphone custom application

Let me explain the application. Before starting my question, I would like to say the following. (for specification of my question) For example in Mac os User Starts iTunes User Clicks on iTunes Store User can see the different applications, videos etc. After he will select specific application/video to purchase it. ID - Password is req...

Read only a portion of a file from disk in objective-c

I am reading a very large file using a NSInputStreamer and sending them to a device in packets. If the receiver does not get a packet, I can send back to the sender with a packet number, representing the starting location in bytes of the packet missing. I know an NSInputStreamer cannot rewind and grab the packet, but is there another w...

iPhone - parsing nsdata to get multiple files stored there.

I'm trying to find a the new line and returns that are inside a nsdata object that I'm parsing . Here's some code: uint8_t *arr = [receivedData bytes]; NSUInteger begin1 = 0; NSUInteger end1 = len; uint8_t *arr1 = (Byte *)malloc(sizeof(Byte)*((end1-begin1+1))); int j = 0; for (int i = begin1; i < end1; i++){ ...

iPhone- Can 2-channel audio podcast files output to mono bluetooth earpiece?

iPhone 3G using OS 3.1. Can iPhone be enabled to play audio podcasts via a one-ear bluetooth headset (terminology issue- headsets mean both one-ear and two-ear units.) VoiceMemo audio files can output to a one-ear bluetooth headset (as can phone calls of course.) But audio podcasts files cannot. Is there a setting change that can ac...

Iphone App vs. Offline Web App. Which way is the smartest?

I think about starting from scratch building a small application fullfilling two technical requirements: should be usable on iPhone should work offline There are two obvious alternatives here to choose between A real iPhone application with offline capabilities A web app using HTML5 offline, Google Gears or similar Having no iPho...

can client pay from his apple account to company from iphone application

From My Previous question http://stackoverflow.com/questions/1415914/sending-request-to-apple-from-iphone-custom-application/1415927#1415927 Here, I have added more specified my question. Suppose my application has implemented followings. Lets take an simple example I have developed an application, for mobile dealer. User can see t...

Custom UITableViewCell Subclass works fine, but subViews don't autohighlight when Selected

My UITableViewController uses a custom UITableViewCell Subclass. The subClass (QuoteCell - loaded from NIB) has a few UILabels and a UIImageView on it. Works fine, however, when I tap on the cell, the cell highlights, but the UILabels on the cell don't reverse colors. I thought this was stock behavior?? Any help appreciated, Thank...

What version of the iPhone/iTouch to target

I am about to release my first app to the iTunes store. What version of the iPhone/iTouch should I be targeting to hit the most people? The default in XCode is 3.0. ...

How to show an image representation of a movie selected by UIImagePickerController

I am using UIImagePickerController that gives user to be able select an existing photo or use the camera to take an image at that time. And i can show that image in my application with UIImageView. Now i want to use this ability for movies also. But i couldn't find any way to show the selected movie as an image in my app, just like the ...

WiTap problem, probably 10.5.8 firewall

I've built the WiTap example both for my iPhone and for the simulator. Bonjour finds properly the other part on both, nevertheless (a) if I click the iPhone name on the simulator, all works well (the "game" does start) (b) if, though, I tap the Mac name on the iPhone, it goes blue--and nothing happens (in the code, the stream delegate ...

UITableViewController - UIButton behavior

I have a UITableViewController that has a button in the background the size of the screen. The button accepts touch events to hide the keyboard when the user touches outside of the tableView. The UITableView is set to Grouped style and has its backgroundColor set to [UIColor clearColor]. self.tableView.backgroundColor = [UIColor clea...

Multiple UITableViews on one UIView

I need to have two UITableViews on one UIView. I can make it work with one, here is the code: - (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView { return 1; } - (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section { return [contentOne count]; // sets row count to number of ite...

popNavigationItemAnimated error

Hello, I am getting an odd error: 2009-09-12 18:47:15.967 CraigsAlerts[10057:207] * -[UINavigationController popNavigationItemAnimated:]: unrecognized selector sent to instance 0x191c7e0 2009-09-12 18:47:15.968 CraigsAlerts[10057:207] * Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** -[UINavigationC...

Create UiImage from NSData

Below is code I copied (from this site) and modified only slightly since the original code would not compile. I want to manipulate the byte array for edge detection and eventually simple changes to colors, but first I wanted to get the basic code working. Currently, the system compiles and runs. It displays a badly drawn elephant on scre...

CGLayers not blending

This is what I am trying to do: create two CGLayers, A and B. Put B over A, using a blend mode, get the resulting image. This is the code // Begin the drawing CGLayerRef objectLayer; CGContextRef fundoContext, objectContext; CGRect backRect, objectRect; CGFloat w = myImage.size.width; CGFloat h = myImage.size.height; CGSize sz = CGSiz...

iPhone Camera and Image Chooser

Hi Everyone: I have found a lot of information on using UIImagePickerController to let the user choose the image they want from the Photos application's data. I am wondering how I can create this same effect on 3.0, as it doesn't seem as if a lot of the old code works anymore. In addition, I would like the user to be able to take a ne...

In Xcode, project settings, how to add relative path?

How it looks? thanks ...