ios

iOS & Google Analytics: Does pointing to an rss feed register in web analytics?

If an iPhone application has a blog section which parses and displays individual pages from a feedburner feed, will those hits show up in the web Google Analytics? If not, if I add Google Analytics to the iOS application itself, is there a way to combine the data? ...

Does MongoDB work on iOS?

The title pretty much says it all: Has MongoDB ever been compiled to work on iOS devices? I know the terms of the App Store do not allow an application to launch a subprocess, so the DBDirectClient class would have to be used to access the data files in-process. Any thoughts? ...

Forcing iPhone Microphone as Audio Input

Hi everyone, I am developing an iOS application (targetted specifically for iPhone, at the moment) that requires the application to record audio only from iPhone internal microphone (even when headphone/headset is plugged in), and playback at headphone (let's assumed headphone is plugged in for now). I am wondering if this is currently...

iOS SDK CGAffineTransform Angle Question

I need to get angle in radians. I have: CGFloat angle = asin(myImage.transform.b); This seems to be not working. I need to extract the angle of 'myImage' at any moment in time. How would I extract this? ...

Can I use UITabBarController as a simple viewController switcher?

Hi, I'm creating an iPad app based on a UINavigationController (with the bar hidden) so I can push and pop other viewControllers for navigation around the app. However, I am now wanting to add a section in which there are two viewControllers that I want to be able to switch between, so in other words they are side-by-side, rather than h...

Assigning a selector crashes on iPod touch 2nd generation

Update: problem magically disappeared, see comment I have a function which works fine on an iPhone 3G, iPhone 3Gs and simulator but crashes on an iPod touch 2nd generation. - (id) initWithDelegate:(id) delegate data:(NSData *) data finishSelector:(SEL)finishSelector{ if(self = [super init]){ _delegate = dele...

iOS and Facebook Graph API: Inconsistent authorize issues

I'm using the official FBConnect library for iOS and trying to get it working in my iPad app. Here's what's strange: when my friend logs in using the call to authorize:permissions:delegate, everything works fine: the dialog asks for his authorization to connect to Facebook, the fbDidLogin delegate method gets called, all is well. Howeve...

How do I remove a view from a super view without unloading the superview?

I'm trying to something like [view removeFromSuperview] however when I do it appears from what I've seen and what I've read in the apple documentation that the normal behaviour is to remove the superview from view as well (unless I have misread). I'm wondering how to simply remove a view from the superview, i.e. in the case of creating ...

What is the most efficient way to get a list of a Facebook user's friends' names in the Facebook iOS SDK?

I want to use the Graph API. And I want to load them into a UITableView. Also loading entire user details is slow... Is there a way that I can make it faster? One more thing: Is there a way that I can load a page on Facebook in the login window that is provided by the Facebook iOS SDK after the user logs in? Pretty much I want to load a...

IPhone: Prepare for App Submission - Access Denied?

Hi, this question is for iOS Members ($99 a year plan), I was just wanting to look up the documentation on "Prepare for App Submission" in the following link: (after you login) http://developer.apple.com/appstore/resources/submission/ but it gives me an 'access denied' message. does it do the same for you or is it just me? Thanks ...

How do I make the same Facebook object available to all my code in my iOS Facebook SDK project?

I've tried passing in the Facebook object which I named facebook as an argument into classes that rely on it. However, is there a way to use it in a sort of global way so that way I don't have to keep on passing it around between objects? ...

Superglobals in Objective-C and iOS

Hey! I'm trying to add some sort of a superglobal in my app. It will only store a small integer, but I need it to be accessible from anywhere in my app. I know you can use the delegate for this, but wouldn't it be easier if you could just set a superglobal in your application (of course it has to be alterable)? So, what is the best wa...

iPad ViewController configuration for document-based app

Hello, I was wondering what would be the best configuration of view controllers and views for an app that I’ve been planning out. Conceptually, the way I would like to lay out the app is with an initial loader/browser view, likely with document thumbnails. When a user chooses to open one, a new view comes up that forms the main document...

Quicker if-statement: if `variable` is "value" or "value"

Hey! How can you compare against multiple possibilities in one argument? Example: if ((integer == 2) || (integer == 5)) if ((string == "hello") || (string == "dolly)) Would save me a lot of code if you could write that like this: if (integer == (2 || 5)) if (string == ("hello" || "dolly")) ...

Graph API and iOS

How can I use/implement the new Graph API from facebook in iOS programming (objective C)? Also parsing the JSON file returned by the API? I can't seem to find any examples out there. Facebook resources doesn't give too many details on iOS development. ...

How to build universal ios static library

Hi I'm trying to build a static library that I can use with both ios3.x and ios4.x. I can build a static library with ios3.0 that works with another project in ios3.0 but won't compile in ios4. The same is true going from ios4 to ios3. Here's how to recreate: Open XCode 3.2.4 and start a new project that's a Cocoa Touch Static Libra...

UIPopoverController & UIImagePickerControl: "Popovers cannot be presented from a view which does not have a window"

I am trying to display a UIImagePickerControl in my iPad app. At first, the debugger told me that I needed to put it in a popover when doing it on an iPad. So I wrote the following code: UIImagePickerController *imagePicker = [[UIImagePickerController alloc] init]; imagePicker.delegate = self; imagePicker.sourceType = UIImagePickerContr...

Blocks instead of performSelector:withObject:afterDelay:

I often want to execute some code a few microseconds in the future. Right now, I solve it like this: - (void)someMethod { // some code } And this: [self performSelector:@selector(someMethod) withObject:nil afterDelay:0.1]; It works, but I have to create a new method every time. Is it possible to use blocks instead of this? Basi...

How can i make visual keyboard appear above my UIToolBar?

I have a UITextView at the midle of View, UIToolBar at the bottom of View. I want visual keyboard appear above UIToolBar when i touch on UITextView. How can i do it? ...

unique values of custom object NSString property in nsarray

I have an array which stores custom objects. Objects are of type Venue which have a property defined as name(which contains the names of venue). Now I want to filter out objects with unique names. This is how I was trying to do. NSSet *uniqueVenuesSet = [NSSet setWithArray:[venueArray valueForKey:@"name"]]; NSMutableArray *uniqueVe...