iphone

popToRootViewControllerAnimated and reloadData

Hello, I've written a tabbar application where on the first tab i have a tableview with a navigation controller. The tableviewController gets pushed every time i select a row. This is a remote directory on a Server e.g. /dir1 When from the second tab i select a differnt root directory e.g /dir2 then when i go to the first tab i want t...

What can be causing the problem that I can't make a screenshot from my iPhone app in the Organizer window?

For some reason, when I press "Capture" while my device is connected and running the app (launched via Build & Run in Xcode), nothing happens. Never get a screenshot. iPhone OS 3.0. What can be the problem. ...

Programatically pass touches to UIScrollView to scroll

Hey SO, So basically I'm trying to make UIScrollView only scroll on higher angles. As in right now if you move your finger 10 degrees off horizontal, the scrollview will scroll. I'd like to push that up to, say, 30 degrees. After doing some reading, I established the best way to do this would be to put a subclassed UIView on top of t...

Objective-C : Start an object on a background thread -- interact as usual?

I would like to have an object be callable from the main thread MyObj* backgroundObject = [[MyObj alloc] initInBackground]; BOOL result = [backgroundObject computeResult]; But have all the methods of backgroundObject compute in another thread. And also have backgroundObj be able to send messages to it's delegate. How can I do such a ...

iphone error when unit testing: Expected '=', ',', ';', 'asm' or '__attribute__' before '*' token

I get the following error when I try to build (Build->build) a unit test. My unit test is a logic test (it does not run on the device). Things that are probably related to my problem are: I am using libxml2 and a wrapper around it (which i found at cocoawithlove). This wrapper has some C functions defined (it is not an Objective C cla...

XCode Developer Documentation crashes after clicking any link on the startup screen

I just installed XCode 3.2.1. When I open the Developer Documentation and click any link on the startup screen, XCode crashes. Has anyone run into this problem? Also hints as to how to debug would be excellent -- I've only been using XCode for a week. I can still get into the documentation if I open some code and then right-click a s...

How can I open Rss feeds from YouTube, Blogspot and Twitter into my app.

I created an Iphone App that gets RSS Feeds from My YouTube Channel, My Blog and My Twitter. I works great except for when I click on any off the feeds such as one of my videos it takes me to Safari to watch it. Or when I click on one of my blog feeds it takes me to safari and opens my blog. Is their any way that I can have it open with...

NSString or NSMutableString category for templating

Is anyone aware of a category on NSString or NSMutableString that allows for templating? I'd like to create a template and use tags for variables, then "apply" a KVC-compliant object against the string to have the variables replaced. Or another way of asking... How is templating currently done in the iPhone / Objective-C universe? Is ...

How do I rotate from landscape to portrait upon loading a view?

Hello everyone: I'm working on a module for a project where the screen is in landscape mode when I get it. I have to load a new view, and switch to portrait mode. While this seems simple enough, I have not been able to find a simple solution. Here's what I tried: [[UIApplication sharedApplication] setStatusBarOrientation:UIInterfaceOri...

How to convert Objective C textual (po) representation to real object

Hi, In xcode you can use po object to see a textual representation of a given object. Is it possible to convert from this textual representation to a real objective c object? Thanks ...

How else can I avoid leaking this Core Foundation object?

The following leaks: CFStringRef labelName = ABAddressBookCopyLocalizedLabel(ABMultiValueCopyLabelAtIndex(aMultiRef, indexPath.row)); cell.textLabel.text = (NSString *)labelName; CFRelease(labelName); Wondering if there a way to rewrite it so it doesn't leak without breaking out & assigning ABMultiValueCopyLabelAtIndex(aMultiR...

What does this error mean? malloc: *** error for object 0x103f000: pointer being freed was not allocated *** set a breakpoint in malloc_error_break to debug

What does that mean? Getting this in the console during usage of my app in debug mode: malloc: * error for object 0x103f000: pointer being freed was not allocated * set a breakpoint in malloc_error_break to debug Does that mean I'm over-releasing something? ...

Unable to change UITableViewController color background

TitlesViewController : UITableViewController I have the above code on iPhone development. This is associated to a xib (or nib) file. In this property file I change its background color. The problem is it does not reflect my new background color. Should I be manually loading the xib file to reflect it to my TitlesViewController? ...

How to require fullscreen mode in a jQTouch application?

I'm using jQTouch to develop a version of a website optimized for safari on the iphone. The jQTouch demo helpfully shows how to show an "install this" message for users not using full screen mode and hide it for those who are. When in fullscreen mode, the body should have the class "fullscreen." So you can hide the "install this" mess...

iPhone Table Background Color Problem

I have these two lines of code: Line 1: self.tableView.backgroundColor = [[UIColor alloc] initWithRed:((float) 102.0f) green:((float) 204.0f) blue:((float) 255.0f) alpha:1.0f]; Line 2: ...

ad hoc distribution vs app store distribution.

i want to distribute my app to our few company employees. but when i tried to create ad hoc distribution profile ,it requires device ID for every single device that i want to install my app. it is not possible for me to get IDs.and i am not sure app store distribution actually submits my app for approval (i am not ready for approval yet)...

Create semi-transparent overlay to mimic UIAlertView or UIActionSheet?

In the iPhone app that I am currently developing, I present several "alert" views that mimic the behaviour of UIAlertView and UIActionSheet. These views require non-standard elements that are not available in UIAlertView or UIActionSheet. Rather than attempt to subclass either, I have created my own classes so that I can easily customi...

How to resize UITableViewCell Background in editing mode

Hi I've a table view with a custom image background of each cell. In normal mode the background is perfect and fill all the cell. When tableView enter in editing mode the "-" button appear on left and all the object are indented and in the left I've problem with background: there a white area. Can anyone help me? The background image is...

Custom UITableViewCell with Partially Bold Text

Trying to implement a UITableView of names similar to the built-in Contacts iPhone app where the first name is in normal font and the last name is bold. A quick google suggests this isn't as easy as it sounds due to the iPhone SDKs lack of rich text support in UILabels. One of the solutions found recommended using a UIWebView to format...

Strange memory management issue

I can't identify the object being deallocated, I run my app with Command+Y but despite having MallocStackLogging set to YES and NSZombieEnabled set to YES, when I hit EXC_BAD_ACCESS in my app, gdb doesn't print the memory address of the deallocated object. Any ideas? Apologies if this seems vague, it looks like it's Core Data related, ...