iOS Development is easy with XCode, Swift3, UITableView, cocatouch, let's build iPhone, iPad and Macbook Applications.

Screenshot that taken by iOS when (before) application go into background?

I hope that you all know about it, iOS takes screenshot before your application goes to background. I got it from official document. Remove sensitive information from views before moving to the background: When an app transitions to the background, the system takes a snapshot of the app’s main window, which it then presents briefly […]

How to create pre-signed URL in Objective C for S3 without SDK?

I’m building a mac application and not using the AWS iOS SDK. The GET request I’m trying to build should follow this general format: “Authorization: AWS ” + AWSAccessKeyId + “:” + base64(hmac-sha1(VERB + “\n” + CONTENT-MD5 + “\n” + CONTENT-TYPE + “\n” + DATE + “\n” + CanonicalizedAmzHeaders + “\n” + CanonicalizedResource)) As provided […]

Undefined symbols for architecture x86_64 in Objective-C

I am attempting to implement the AVFoundation example code found here in an Xcode project: http://developer.apple.com/library/mac/#qa/qa1740/_index.html#//apple_ref/doc/uid/DTS40011007 The only modifications I have made were to remove references to autorelease, release, and retain because I have automatic reference counting enabled for the project. Having successfully resolved those build errors, I am now getting “Undefined symbols for architecture […]

How to change marker icon?

I was wonderring if there is a way to change those red pins that are used as markers. And if there is a way, how to do it?

Output of the Program?

#include<stdio.h> int fun(int, int); typedef int (*pf) (int, int); int proc(pf, int, int); int main() { printf(“%d\n”, proc(fun, 6, 6)); return 0; } int fun(int a, int b) { return (a==b); } int proc(pf p, int a, int b) { return ((*p)(a, b)); } // direct link of program : http://codepad.org/fBIPiHGT

Converting Long 64-bit Decimal to Binary

OK, what I’m trying to accomplish is fairly straightforward although I’m still having issues. This is my code : – (NSString*)toBin:(long)dec { long num = dec; NSString *res = [NSString string]; for (long i=63; i>=0; i–) { long div = 1<<i; if ((num&div)==div) res = [res stringByAppendingString:@”1″]; else res = [res stringByAppendingString:@”0″]; } return res; […]

Animation is causing an image to stretch

I’ve taken the day to try to understand animations better. The next code works great and hides my tabbar. The problem is that it will stretch every UIButton that is near it. Including a custom button on the tab bar. If it touches another layer of image it will stretch it. Any idea how I […]

Audio file doesn't play in iPhone 5

I use a code for playing a .caf audio file, the same code works good in an iPhone 4s and an iPad 2 but doesn’t play at all in a iPhone 5… this is the code: -(IBAction)checkSound:(id)sender { NSURL *url = [NSURL fileURLWithPath:[NSString stringWithFormat:@”%@/Lunatic.caf”, [[NSBundle mainBundle] resourcePath]]]; NSLog(@”%@”,url); NSError *error; self.audioPlayer = [[AVAudioPlayer alloc] initWithContentsOfURL:url […]

subviews are not receiving touches

I have the main View controller which adds 2 subviews. – (void)viewDidLoad { [self init]; [super viewDidLoad]; //To shrink the view to fit below the status bar. self.wantsFullScreenLayout = YES; //We start off by displaying the background Images. [self displayMenuSceneBackground]; //Then we show the Menus. [self displayMenuSceneMenu]; } Here we add the subviews to the […]

Save NSLog into a Local File

I’m learning how to develop for iPhone and i need to save de NSLog output on a local file on my machine to analyse the result in because I`ll run the application for a long time and I need to check after some hours running what was the output (and I want to save the […]