I'm designing a pedometer application for the iPhone. Given the number of steps a user has taken, how do I determine the distance in miles they have traveled?
...
Hi, I have a text file with some strings in it, I am able to access the text from the file by using [NSString initWithContentsOfFile] function but what I want to do next is remove the whole text from that file but leaving the text file there as my application will continue to feed strings of message into the file. I've looked through NSS...
NSXMLParser allows SAX parsing of either an NSData block or from a URL source.
The problem is that both these methods require the entire XML source to be known before parsing begins.
Suppose I have a stream of XML Data (say a sequence of NSData objects) and I want to process the stream using NSXMLParser or another cocoa class, how can ...
Hello,
EDIT: Issue has been solved(partially):It is a simulator bug. I've compiled and tested this on two devices with iOS 3.1.3 and 4.0. The exception was handled correctly. Be careful, the simulator is your enemy!
this is driving me crazy. I don't know how to enable exception handling in my project. Look at the code and debugger outp...
I have a custom UITableViewCell. It has a UIView which is added to the "contentView" of the UITableViewCell. For any update, I'm redrawing that UIView by calling its "setNeedsDisplay" and implementing drawing inside "drawRect" method of the UIView.
The UITableViewCell overrides "willTransitionToState" and according to the bit mask value...
Dear all experts,
I need to use 3 UIScrollView to Display images with 3 parts, Head, Body and Leg, and before the game start, the UIImageView will be displayed randomly in UIScrollView. User have to scroll them to match it as a Person.
I use three Array:
headArray, bodyArray and legArray to store the image name;
and Then addsubview to...
Hi There,
Does anyone know of any library to convert .caf files or .aif audio files to mp3 format.
Im recording these on iPhone using AVAudioRecorder pibrary but need to convert them to mp3 on server side.
Your help is much appreciated.
Really stuck on this one.
...
I have a case where a portrait only mode view needs to be pushed into a navigation controller which has a landscape mode view as its current view.
Although I have reimplemented
-(BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation {
// Return YES for supported orientations
return (interfac...
Hello Guys,
Please, advice me how safe is to integrate three20 framework in our project. Previously i heard that some private API issue and apple rejecting the app. Did any one done the three20 framework and apple approve it with out any issue ?
Please, advice ASAP.
Thanks
...
Is it possible to open another app, like Camera, from a third-party app? I know there are URL schemes - http://wiki.akosma.com/IPhone_URL_Schemes - but I just want to open an app, not send any data to the app.
...
Hi
I'm building a socket , using
CFStreamCreatePairWithSocketToHost(kCFAllocatorDefault,
(CFStringRef) yourHostAsNSString,
yourPortAsInteger,
&myReadStream,
&myWriteStream);
and I s...
I know this is somewhat a noob question but anyways im having hard time figuring it out.
Im trying to cancel out the touchmove event on an UIImage when it colide with other UIImage.
-(void)touchesMoved:(NSSet *)touches withEvent:(UIEvent *)event {
UITouch *touch = [touches anyObject];
CGPoint currentPosition = [touch locationInView:sel...
Hello ! Every one.
In my application I am reading an HTML page to a string.
HTML Page contains many tags, new lines & many other characters.
<style type="text/css">
h3{
font-weight:bold;
line-height:18px;
font-family:Arial;
font-size:12px;
text-align:justify;
color:black;
...
Hi all,
I am new in iphone application development.
My problem is that my sqlite database is uploaded on the server.I have the link and port number of the database.How i access the database from the server.
if possible then provide any sample code.
Please help me.
Thanks,
Arun
...
Hi, I've created a button that when pressed displays a subview which contains a "Back" button. I would like the current view to be dismissed when the Back button is pressed. I have tried in the following way but of course it does not work as the compiler does not recognize CurrentView which is defined inside (IBAction) ShowThisView. Any ...
HI all,
is there any way round,in which we can reload UIView,like we do in table view, reloadtable?
is it possible?
regards
shishir
...
How to wire up the values for glDrawElements?
I need a simple textured square example (2 face, normals, textCoords, nothin' more).
I tried to do it (the arrays at glDrawArrays implementation works fine, but something went wrong when I create the indices and all), but the screen was empty.
Please shed me a light, I've googled the whole ...
hi all,
in my application i uploaded sqlite database on the server.
problem is that i have no knowledge how to access the database from the server in my application.
Please tell me anyone how i access database from the server.
...
I have put a button over a toolbar.But when i press that button,my selector is not called and application crashes giving following error
Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '* -[ChatViewController changeButtonImage]: unrecognized selector sent to instance 0x119570'
here is my code..
UIToolb...
Hi there,
I'm using this code to do shake detection, and for the most part it works fine:
- (void)motionEnded:(UIEventSubtype)motion withEvent:(UIEvent *)event {
if (event.type == UIEventSubtypeMotionShake) {
if ( event.subtype == UIEventSubtypeMotionShake )
{
NSLog (@"Shake Called");
}
}
I believe for this to work, ...