objective-c

Detect gesture accelerometer

hello I'm creating an iPhone application. My application needs to detect the movements of the accelerometer and report the case of movement by the user. In practice I have to constantly check that the coordinates received from accelerometer are equal to the coordinates saved in my movement. My problem is that its implementation is not si...

What is the use of the libobjc.A.dylib framework???

What is the use of the libobjc.A.dylib framework??? ...

problem with intergating facebook session

hello I am using Facebook in my music application where user post comment on wall paper after listening the songs . So problem arises that user have to login again for next song. so please provide me code for session retains when he clicked on the tab where it written "keep me login". Thanks ...

changing the colour of Button

how can I change the button colour when ever I click that button please help me out ...

NSLog without new line

Is there any function that does what NSLog does but without the new line at the end? ...

how access mysql remote database

hello, i m creating inapp purchage subscription module, in this app i want to access remote database but problem is that how i connect my objective-c code with the mysql on the server, i am not found any sufficient refrence please help me if any refrence or solution is there. ...

How to add custom UTI in xcode app for exported plist xml format

Hi All, I am working on one cocoa application and exporting some data stored in NSArray to plist(XML) format. I want to give custom extension and icon to that exported plist.This custom extension plist file will be imported and exported by my application only. I tried few links but unable to make that working. I am using xcode 3.1.4 an...

Rotate a UIImage or UIView to a particular angle, NOT an amount of angle.

Objective-C for iOS. How do I rotate an image or view TO a particular angle. I have tried the two methods below, but both rotate the AMOUNT of angle, not TO the angle. Basically I would like to call a method to rotate to 90' and then say call again of 180', and the image/view to finish at 180', NOT an addition of them both (270') which ...

How to create a const NSDate

I am trying to define the equivalent of DateTime.MaxValue (C#) but in Objective C. I don't want to keep creating NSDates every time I use it so I wish I had it as const. The problem, the compiler returns "Initializer element is not constant" Here is the code static NSDate* DateTimeMinValue = [NSDateFormatter dateFromString:@"00:00:0...

How to set an instance variable from a class method in ObjC

I have a singleton initializer which is a class method. I want to set instance variable data from it. How can I do this? ...

How to check the last char of an NSString

Hi, everyone, I want to ask a question about the NSString * in objective C. Can I check the last char of a NSString * object? Example: NSString* data = @"abcde,"; if(data is end with ',') // I don't know this part // do sth Thank you very much. ...

how to set image in button

How set image in button when ever click the button image show me that button run.backgroundColor = [UIColor redColor] I try this but it doesn't work, ...

How to badge file and folder using cocoa

I want to badge file and folder with some color(image), any idea how it can be achieved I tried with icon service, it work for files but it is not working with folders. I saw this behavior working Dropbox(https://www.dropbox.com/) (10.4, 10.5 and 10.6)- any idea how can this be done? The following was very close one for me, but it is n...

problem with intergating facebook in my application

The message which is to posted on wall of facebook is automatically open without clicking facebook tab here is code which show message to be post on wall of facebook - (void)postToWall { FBStreamDialog *dialog = [[[FBStreamDialog alloc] init] autorelease]; dialog.userMessagePrompt = @"Enter your message:"; dialog.attachmen...

Difference Class and Instance Methods

Hi, Whats the difference between class methods and Instance methods. Why do we need them separately? Can somebody please explain? Class and Instance Methods • Instances respond to instance methods - (id)init; - (float)height; - (void)walk; • Classes respond to class methods + (id)alloc; + (id)person; + (Person *)sharedPerson;...

Access SQL database remotely from iPhone app

I am trying to access an SQL database remotely. Can someone give me a hint or idea about how to do this in the iPhone? ...

why is objective c considered a simple langauge?

I have heard it said that Objective c is a 'simple' language, i.e. in terms of it's language features. It's really the only language that I know but I did a bit of Java before and, in terms of language features, they seem to be pretty close. I have never touched C++. Is there more features to C++ compared with Objective-C and if so, is ...

Embedding a Prolog engine in Obj-C projects

Hi all, I'm looking for a light-weight Prolog engine to be embedded in an Obj-C application under Mac OSX. In Java there are some excellent implementations with the characteristics I need: deployability, lightness, dynamic configurability, integration with Java and ease of interoperability. Can you recommend something similar in C/C++? ...

Want refresh subview(UIWebView). How to..?

Hello, Good day ! : D My first app close to final. But, I can't go next. Help !! T _T I Want >>>>> If first list( at firstview) click, Sub view load "http://google.com>" and then back to firt View, second list( at first view) click sub view load "http://yahoo.com>" But Now >>>> If first list click, sub view load "http://google.com>". ...

Creating a custom Facebook login form

Does anyone know if it is possible to create our own user interface for Facebook connect instead of having to use FBLoginDialog? If YES, how? IF NO, can I format FBLoginDialog to have the look that I want just like the FBStreamDialog (POST message to wall)? Any suggestion would be highly appreciated. ...