iphone

starting iChat session in iPhone from web app

This is really just a "what-if" type question, so forgive me if it is either ridiculous or ridiculously easy... I have a client whose site offers a "chat with a consultant" option that you see on many sales and support sites. We were wondering if there was a way that iPhone users (or any user, in theory, but mostly iPhone) could click t...

Image cropping problem

Hi Guys, I have written following code for cropping image in oval. but not getting expected result. The original image size is 382x453. and put an eclipse at CGRectMake(50, 100, 100, 150). But image always crop from the 0,0 position of the original image. I'm doing somthing worng in this code. please help me out where i'm wrong. Many th...

Communication between view controllers

Given the section of an application which has a UINavigationController and 2 levels of UITableViews (i.e. a row is selected on the root controller which pushes the second controller onto the navigation stack) I have the following questions: 1) There is a User object which is required by both controllers. What is the best way to communic...

how to draw line with animation?

I have implemented game application in which i want to draw line between two object.I have drawn line between two objects.But i want to draw with animation.can u advise me which animation i have to used between two points. Edit:My excatly question is that: Suppose there is two point like start point(100,100) and endpoint(300,300).I can ...

Activity indicator not animating=iphone

In my application i am uploading some images to the servelet, which takes some time to complete upload. I have implemented an uiactivityviewer using IB and connected it to an outlet named acticityIndicator. But when i call [activityIndicator startsAnimating]; nothing is happening!!! What might be the problem. i've debugged the code, the...

Change font size with UISlider

Hi, I am trying to change the font size of my UITextView using the value from a UISlider. i need some tips or sample code :) thank you . ...

How can I make the 'return character' for a text with several lines in an xml tag, which I parse then put in a UItableView?

I want to display in a UItableViewCell, text like line1 line2 I get it from an xml tag like line1 line2 I've tried a lot of things, like: <br/> (also &lt;br&gt;), \n which only displays "line1 \n line2", <![CDATA[<br >]]> which only displays "line1 <br> line2". Thanks for the help ...

Landscape UIView in a UITabBarController

Hi, I have a UITabbarController with (so far) two navigation controller items. I can get the application to rotate by adding the shouldAutorotateToInterfaceOrientation to each class... but thats not exactly what I want. What I want to do is to add a button in the UINavigationBar in one of the classes. When this button is pressed I want...

help! when playing a sound the animation freeze\pauses

basically whenever i play a sound the animation slowing down or pauses, what to do ??? sound size 20kb mp3. animation size 5kb png. code: - (void) startAnimation { [UIView beginAnimations:nil context:nil]; [UIView setAnimationDuration:0.8]; CGPoint destination = CGPointMake(152,20); pink.center = destination; [UIView commitAni...

Objective-c with sql-lite on iPhone

Hello guys! Can you give me a good start for this? Thanks! ...

Button Image Changing which is in UITableviewCell?

Hi, i have one button with image for selection in UITableviewCell.i have added button action as toggleButton method.if i touch button in particular Cell, the image of Button of Corresponding tablecell is changed.but i when i scroll tableview the changed image is in another cell.how can i avoid it?please see my code….will you tell what i...

XCode crashes when adding .m4a file to resources

I created my own small .m4a file with GarageBand, for use in my app on the iPhone. Everytime I try to Add existing file, XCode crashes when I select the .m4a file. The file itself will play nicely in QuickTime Player and iTunes. Any workarounds? ...

Does anyone know where to find an "in-app-payment" example?

In an application I am developing I need to integrate the In-app-purchase concept, I have read the apple documentation but still don't completely understand how to completely integrate the system and make the call. Does anyone know if there is an example out there to help me put me on track? ...

Howto: Insert rows into Sqlite quickly on the iphone

Whats going to be the fastest way for me to insert 26,000 rows into a new sqlite3 table on the iphone? My naive implementation was to create a file foo.sql looking like this: BEGIN TRANSACTION; CREATE TABLE user_db.places ( place_id integer primary key, -- cornell id less the leading L lat real not null, lng real not null...

how to program drawing from a deck of card where value and suit is unimportant?

Hi, i know that there are many ways to program a deck of poker cards where value is important after searching on the net. My problem is that my "deck" of cards is a simple array with value as "card name" (example 1 = Ace of Spades) Do i randomize my current Array with NSMutableArray and then remove index 0 everytime the card is being "...

Core data migration add fields problem

I have core data model and sqlite databse with data. Entity Bla: int:f; text:baar and model class @interface Bla { } @property(retain) NSNumber *f; @property(retain) NSString *baar; @end; @implementation Bla @dynamic shared; @dynamic isEBird; @end; I add field BOOL:isGood to entity. I must do something to migrate to n...

desc limit 50 equivalent in Core Data / NSPredicate

Hi, I'm working on an iPhone and I'm using Core Data as my store. What I'd like to do is list the top 50 entities in descending order by their height. I'm struggling to find out the syntax for the predicate. ...

iPhone SDK - Async Behavior?

I have a IBAction that looks like this: self.title = @"Logging in ..."; [MyClass myLongRunningOperation]; My Problem is that the view controller title does not get updated until the long running operation has finished. It seems like its put in a queue for later, while my long running operation executes right away. I'm pretty new to t...

XML parsing iPhone

Hi Guys, I am having this string: [?xml version="1.0" encoding="UTF-8"?] SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="urn:methods" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ns2="urn:PingdomAPI" xmlns:SOAP-ENC="http://schemas.x...

iPhone SDK trimming audio file

Hi I have implemented a audio recording feature using AVAudioRecorder with AVSampleRateKey as 44100.0 and its saved as .caf. Once the audio is recorded, I want the user to be able to trim the audio from both the ends if required. Can some one please help me implement this? In my case since the AVSampleRateKey is 44100.0, 44100 bytes re...