iphone

Asyncsocket VS NSstream

Hi, I have to create an sample code that connect to a socket server, and then be able to send multiple NSString through the socket. In the begging i start using NSStream objects, but i had a problem to reuse the socket (maybe i'll post another question if the nsstream solution is the best), and when i google socket for iPhone programmi...

Why should a self-implemented getter retain and autorelease the returned object?

Example: - (NSString*) title { return [[title retain] autorelease]; } The setter actually retained it already, right? and actually nobody should bypass the Setter... so I wonder why the getter not just returns the object? It's actually retained already. Or would this just be needed in case that in the mean time another objects get...

iPhone BitmapImageRep

I have a buffer which has JPEG image data. I need to display this image in UIImageView. I need to convert this image buffer into an object of UIImage and use it as follows NSData *data = [NSData dataWithContentsOfFile:appFile]; UIImage *theImage = [[UIImage alloc] initWithData:data]; I get the image displayed but with a low resolution...

NSOuputStream writing multiple times

Hello, I'm trying to use the NSStream objects to open and then write and read on a socket but i have a problem. I don't know how to write on the socket, after i have opened it. Here is how i have done 1) first openning the socket : NSURL *website = [NSURL URLWithString:urlStr]; if (!website) { NSLog(@"%@ is no...

Objective-C on iPhone release problem

I have a problem that I am getting EX_BAD_ACCESS when calling release on an NSStream object in my dealloc on the iPhone. The following code - (void)dealloc { DLog(@"dealloc started for: %@",self); @synchronized(self) { lookupCount--; if (lookupCount==0) { UIApplication* app = [UIApplication sharedApplication]; app.ne...

Testing CoreLocation on iPhone Simulator

Is there anyway to test CoreLocation on the iPhone Simulator? All I require is to be able to set the location myself and have CoreLocation return it. ...

iPhone Application Name Availability

Is there a way to check whether an iphone application name is available to use? Would a search on iTunes and checking to see if there is an existing application already out there be indicative that an iphone application name is available to use or not? ...

"Refreshing" an XML feed on iPhone/Mac OSX

Hi all, I'm curious for those of you who are building iPhone apps based on REST/SOAP/XML-RPC or simply pulling down a dynamic XML feed, what does it mean exactly to you when a user says 'refresh' the feed? The straight forward way is to populate some collection, say an NSMutableArray, with whatever you bring down from the feed. If a wi...

Persistent rightBarButtonItem Property of UINavigationItem

This may be a stupid question, but is it possible to keep a right UIBarButtonItem across multiple views managed by a UINavigationController? I have a progression of views that often share the same right UIBarButtonItem, but when I push a new view to my UINavigationController, I have to redefine the button every time, even if it hasn't ch...

iPhone and Crypto Libraries

Hi, I think I'm going to have to use the Crypto libraries in my iPhone application. I wanted to ask you about the implications regarding the crypto export policy applied by Apple. Do I need to do something extra (such as filling forms etc.) 1) If I use hashing with MD5. 2) If I use symmetric encryption. Thanks, ...

Changing language of tab bar elements

Hi: we're developing an iphone application to be distributed in Spain. It contains a Tab bar, but we're not quite sure how to change More and Edit into Spanish. I'm sure there's a simple solution... anybody know a way to do it? Thanks, Antonio ==== Edit 1 ==== This is how we add the tabbar. As you see, we create a tabBarItem for eac...

UISlider with sound effect and vibration

Hi all, I need to do a lot of things with UISlider. First of all I want to know what are all the things are possible and what are not. Please give me ideas for the doable ones. I need to add a slider control in my iPhone application (that should resemble the one which is displayed in the iphone when the phone is getting charged). Can...

alternatives to XCode for iPhone development? (OR: how to make XCode suck less?)

I've been a Java developer for 10+ years now, and have come to love the power that modern IDEs provide for things like refactoring, finding dead code, finding "usages of", etc. I'm starting to do some iPhone dev on the side, and am utterly frustrated by the lack of such features in XCode. There is no "find usages of this method/class" ...

Updating UIAlertView title

I am uploading a bunch of files from the iPhone to a web service. I want to have a UIAlertView on screen with a UIActivityIndicatorView inside. I got that to work fine. However, I want to update the title of the UIAlertView as each file gets uploaded. ("Uploading file 1...", "Uploading file 2...", etc.) I know that you can't just se...

Encode NSString for XML/HTML

Is there a way to HTML encode a string (NSString) in objective-c, something along the lines of Server.HtmlEncode in .NET? Thanks! ...

How do I build an xcode project for the itunes store??? Please help!!

Ok, I'm abit of a newbe...need some help... I've got my apps running on my iphone, great..however, to list on the itunes store I need the "universal binary" thing... I've tried finding answers, but I can't seem to find a concise useable explanation to doing this in xcode...I alwase get errors when I try to build a binary...So PLEASE, ca...

Iphone Poll - A 80MB download & install VS a 30MB download & install (But with 25second install time)?

So, I have a database that is 80MB uncompressed. I've gz'd it to 30MB, but it now requires a 25 second "unpack" time when the application first launches. I've written this code in C, making it as fast as possible (no NS* types, minimal code to complete the read from the gz to the write of the new .db). Here's a bit of data on the sizes ...

Is it possible to add info or help text to an iPhone settings bundle?

Several of the Apple-provided apps have informational/help text in their settings. For example, the Keyboard settings shows: which includes the help text "Double tapping the space bar will...". I know I can do this in my app by adding a group footer, but is it possible to do this in the settings app by adding a field to the plist fi...

Streaming "proxy" converting video formats

This is related to my another question Here I'd like to ask if it is in theory (according to video file formats and codecs, etc) possible to have such scenario: 1) Client on iPhone has a reference to video in flv format. It sends http request to converting "proxy" like http://convproxy.com?source=url_of_original_video.flv by just click...

How to resolve Undefined Symbols error?

I'm getting this error Undefined symbols: ".objc_class_name_MyClass", referenced from: literal-pointer@__OBJC@__cls_refs@MyClass in infoViewController.o ld: symbol(s) not found collect2: ld returned 1 exit status When referencing the static method below: [MyClass ClickComment:self.navigationController]; MyClass is defined in a st...