xcode

Debugging EXC_BAD_ACCESS from a NSString

Hello All, I had a EXC_BAD_ACCESS message in my console. I read about the environment variables NSZombieEnabled and MallocStackLoggingNoCompact on this site. I created my environment variables: NSZombieEnabled = YES and MallocStackLoggingNoCompact = 1. In the console, I saw 2010-03-01 19:13:46.924 CruzNomad[7952:207] * -[CFString...

Utility Application and View-Based application

Hi everybody, I'm new to xcode and the iphone sdk. I've been working with the view-based application for quite a while, and I was wondering if a utility application and a view based application involved the same type of coding. Can someone point out the difference for me? Thanks ...

how to update sqlite3 database fields in external source

i need to update my sqlite database which is on the external source(URL). ...

Reading PDF files as string through iPhone application

I am facing some problem in iPhone application development for "Reading PDF". I have tried following code. I know I have used wrong methods for parsing - parsing methods are just used for searching purpose. But I want to convert entire pdf text in to a string. Say for example Apple's MobileHIG.pdf - I have used in this code. @implementa...

TableViewCells width in iPhone

Hi. I'm trying to create a cell on a tableview which doesn't go "all the way" from left-to-right of the screen. Basically, what I need is a cell which (as usual) starts on the left side of the screen, but with a given width, creating a free space on the right. Is there any way of doing it? I wasn't able to find any example. Sorry for...

How to build a static C++ library using Xcode ?

Hello guys, I am trying to create a static library in Xcode using C++ ( All my files are .h or .cpp ). I tried deleting main.cpp and then adding a target to my project to build a "Static" library. Since I'm not using Cocoa, I assumed that I needed to add a BSD Static Library, but I have tried other static library options with no apparen...

Using Localizable.strings in iPhone application

I downloaded the three20 library: http://three20.info/ And I opened the TTCatalog sample project that comes with this library: http://img16.imageshack.us/img16/3183/screenshot20100302at752.png As you can see, there are lots of Localizable.strings files. When I opened the iPhone simulator and changed its language to for example Frenc...

Multiple view controllers with their own xibs, and when they load

Going through many tutorials and with the help of everyone here, I am trying to wrap my head around using multi view controllers with their own xib files. I have one example where there is a : multiViewController and two others: aboutViewController, rulesViewController. In both aboutViewController.m and rulesViewController.m files, I...

OBJ-C: Core-Plot XY-Axis Fixing

I want to fix the axes so that they are always to the left hand side and bottom of my plot space. My current implementation is not enabling userInteraction so no need to worry about scrolling. // Setup plot space CPXYPlotSpace *plotSpace = (CPXYPlotSpace *)graph.defaultPlotSpace; plotSpace.allowsUserInteraction = NO; // Axes CPXYAxisSe...

XCode enable Code-Folding by default

Is there a way to tell XCode fold methods/functions by default when opening a file? ...

A better UIAlert dialog

I have seen several apps that display some form of alert which sometimes require user entry or displays some type of information. Anyway, judging by the designs of the "alert", I would assume they are using something else to display these. My first guess was some form of view but I see that they are smaller in size and are centered in ...

PHP variable to Xcode variable

how can i get an integer variable from PHP page and save it to the integer variable in my program... USInteger *number = an integer variable from PHP page... ...

Compiling Libs for iPhone projects

I'm new to XCode. My iPhone project is dependent on FreeType. I got the source, but it needs to be statically compiled and included with my project. I tried adding a target and adding the include and src directories but this resulted in 3200 compiler errors, most of which complaining about no build rules. I'm just not sure how to do this...

How can I change interfaceOrientation on UIView

I want set interfaceOrientation in one UIView as LandscapeLeft and Portrait in other UIView. How can I do this? Or maybe change view to new, that designed for portrait on rotating iphone in this mode? how? ...

In my Xcode, why is "Switch to header/source file" not working?

Xcode has a feature which allows you to quickly switch between a {.m,.c,.cpp} file and its corresponding header file (e.g. .h). You can do it from the menu by View > "Switch to header/source file", or by the key stroke ⌥⌘↑ (alt-command-up_arrow). Either way you do it, mine is broken, and mostly nothing happens. The View menu does brief...

Xcode what is the key to tab into the next auto suggested parameter block?

Xcode what is the key to tab into the next auto suggested parameter block? e.g. when typing a method the params are suggested automatically you press TAB to accept but how to you move to the next param ? ...

How To load XML file into iPhone project

I have an XML documment that I want to load for the iPhone, do I need to convert it to a plist first ? if so how ? The xml document has the following code ( for 1 chapter) <toolTipsBook> − <chapter index="1" name="Chapter Name"> <line index="1" text="line text here"/> <line index="2" text=" line text here "/> <line index="3" text=" li...

What's the best way to measure and track performance over various calls at runtime?

Hello. I'm trying to optimize the performance of my code, but I'm not familiar with xcode's debuggers or debuggers in general. Is it possible to track the execution time and frequency of calls being made at runtime? Imagine a chain of events with some recursive calls over a fraction of a second. What's the best way to track where the...

Programatically generating UIButtons and associate those with IBAction

Hello, How do I do if I want to programatically generate a set of buttons and then associate those with IBActions? It's easy if I add the buttons in Interface Builder, but that I cannot do for this case. Thanks in advance! ...

Method Definition Not Found... automatic stub with Xcode?

I don't want to give up before asking, because this is basic functionality in any Java/.Net IDE. The compiler tells me: Incomplete implementation of class... Method definition for '-someMethod:' not found but clicking, right-clicking, praying and Google searching have not gotten me to automatically create a method stub from this. Can ...