iphone

EXC_BAD_ACCESS on startAsynchronous request using ASIFormDataRequest

I am getting EXC_BAD_ACCESS on the Line: [asiUsernameRequest startAsynchronous]; in this code. Spent hours trying to figure it out, but no solution. Any idea? NSString *usernameValue = (NSString*)usernameField.text; NSLog(@"username selected: %@", usernameValue); NSURL *url = [NSURL URLWithString:@"http://www.mywebsite....

Example of UITextField ResignFirstResponder with Monotouch

I'm a newbie. I can't figure out how and where to call ResignFirstResponder to get rid of the keyboard when the user finished entering the text in an UITextField. I'm a bit confused by the UIResponder class. Mono documentation says: "To dismiss the keyboard, send the UIResponder.ResignFirstResponder message to the text field that is curr...

Converting HTML file to PDF file in Iphone.

Hello All, This is my first thread iam developing an application in which i have to convert the HTML contents to pdf file. I had generate the PDF File but don't know how to create a pdf file from HTML format. Anyone can suggest the solution? Thank You. ...

Strategy to keep track of stored files in the documents directory?

In my app, the user can save his input to disk. This is done with NSKeyedArchiver. Currently I simply name my files with a timestamp. But of course, the user may want to load one of them back in to keep on editing them. What would be the most reliable / safe strategy to keep track of those files? I need to present the user a list of tho...

Display html text in uitextview

Hello, How to display html text in textview for example string <h1>Krupal testing <span style="font-weight: bold;">Customer WYWO</span></h1> Suppose text is bold so it display in textview as bold string but i want display normal text.is this possible in iphone sdk. Thanks you, ...

Adding a UINavigationController to a UITabBarController

I have a set of 10 navigationViewControllers i want to the UITabBarController this all just works fine except the fact when i want to see a UINavigationController that is in the "more" tab it doesn't switch to it. it does nothing. if i change that to a UIViewController it just works fine .. ok in the more tab you automatically have a UI...

The Best Twitter API for iPhone

Hi iam looking for the twitter api for my application with sample code . what's the easiest API for the iphone ? thank you ...

How to get the current location of iPhone through code?

How do you get the current location of iPhone through code? I need to track the location using GPS. ...

Get a PDF/PNG as output from a UIWebView or UIView

Is there any way to get the content of a UIWebView and convert it to a PDF or PNG file? I'd like to get similar output to that available on the Mac by selecting the PDF button when printing from Safari, for example. I'm assuming this isn't possible/built in yet, but hopefully I'll be surprised and find a way to get the content from a web...

How to retrieve stored reference to an NSManagedObject subclass?

Hi! I have a NSManagedObject subclass named Tour. I stored the reference to it using this code: prefs = [NSUserDefaults standardUserDefaults]; NSURL *myURL = [[myTour objectID] URIRepresentation]; NSData *uriData = [NSKeyedArchiver archivedDataWithRootObject:myURL]; [prefs setObject:uriData forKey:@"tour"]; Now I want to retrie...

how to set a tableview delegate

Hi, I'm trying to use a tableview without using a nib and without using a UITableViewController. I have added a UITableView instance to a UIViewController Like So mytable = [[UITableView alloc] initWithFrame:CGRectMake(22, 207, 270, 233)]; [mytable setDelegate:self]; [self.view mytable]; Also I have added the following table view me...

How to create an directory inside the documents directory of my iPhone app?

I would like to store files in a specific directory inside the documents directory, so that I can iterate over all these files and show them to the user for selection. Is that possible? ...

iPhone 3DES encryption key length issue

Hi, I have been banging my head on a wall with this one. I need to code my iPhone application to encrypt a 4 digit "pin" using 3DES in ECB mode for transmission to a webservice which I believe is written in .NET. + (NSData *)TripleDESEncryptWithKey:(NSString *)key dataToEncrypt:(NSData*)encryptData { NSLog(@"kCCKeySize3DES=%d", kCCKeySi...

How to extract delegates from ViewController class?

Hi I have the problem that my view controller class has too many delegates and starts to get big. I want to write the delegates in separate classes to keep the view controller class small. For delegates that are programmatically created (like UIAlertViewDelegate) I could do it easily. The problem is in the delegates assigned in Interf...

iPhone: How to get the contents of the documents directory as a NSMutableArray?

How do I get the contents of the documents directory as a NSMutableArray? I can get it as a normal NSArray, but as soon as I try to do anything with that array, my app crashes. Thanks ...

unrecognized selector sent to instance.

I creat a button and response click event,but get error: -[NSCFDictionary numberButtonClick:]: unrecognized selector sent to instance 0x3d03ac0 2010-03-16 22:23:58.811 Money[8056:207] * Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '* -[NSCFDictionary numberButtonClick:]: unrecognized s...

Didn't load images when I test version on Iphone

I use images from resources like that: UIImage *image = [ UIImage imageNamed:@"example.jpg" ]; UIImageView *imageView = [ [UIImageView alloc] initWithImage:image ]; When I test it on semulator it's works. But on Iphone no. Also image with size about 10Kb loaded, with size about 100Kb no. Whats wrong? ...

How to avoid "message superview sent to freed object" iphone

I have this code: CardView *aCardView = [self prendiCartaDalMazzo]; [aCardView removeFromSuperview]; [self.mieCarte addSubview:aCardView]; when i try to add aCardView as as subview of mieCarte then i get this error: objc[4800]: FREED(id): message superview sent to freed object=0x393f130 Program received signal: “EXC_BAD_IN...

How to rotate a UIbutton in Xcode + IB?

I am writing an iPhone programer, and I want to make a button with is rotate 180 degree, I try to use the multi-touch track pad to rotate a UIbutton, but it don't success, how can I do it? or I need to do it by code? ...

iPhone: Hide the title of navigation bar without remove it

Hi, I have a customized navigation bar with a image background. I do want to show the title on the background but I need its text for the back button in the next view. How can I do it please? Thank you ps: self.title=@"" will not put (naturally) in the back button the previous title. ...