I have a sprite and if it is touched the touch should be recognized. I used the coordinates to do so. I took the coordinates (min x, min y, max x , max y)of the sprite image. But The sprite image is not a rectangular shape. So, even if I touch the coordinates outside the sprite and inside the rectangular bounds the sprite is recognized....
I have to present an alertview when my app starts. My app supports both landscape modes.
Despite the landscape mode the device is when the app starts the alertview always shows in portrait.
I have tried to use the accelerometer to detect the interface orientation before the orientation notification and I have the correct orientation 2...
I am trying to implement a control to edit text that will display the text in multiple colors. None of the solutions I have attempted yet have been good enough.
UITextView cannot accomplish this. All of the text must be the same color.
Using CoreGraphics to draw the text does not allow the text to be selected.
Using a UIWebView, DIV ...
I have issue with userlocation in mkmapview.
The thing is that i have navigation controller which pushes mapview , as soon as it pushes it userlocation is queried. But if user pop mapview view before userlocation animation is finished , it throws exception because animation is trying to access deallocated mapview instance.
So my quest...
I have an app that is a list of tasks, like a to do list. The user configures the tasks and that goes to the SQLite db. The list is displayed in a tableview.
The SQL table in question consists of a taskid int, groupname varchar, taskname varchar, lastcompleted datetime, nextdue datetime, weighting integer.
I currently have it working ...
Hello All,
When I return from an adMob ad by hitting "done" the content of my app has disappeared ! All that remains is a background image I had attached directly to the main window. Oddly I can still hear the result of my touch events from my main screen (which is now gone).
This may be related to the issue some people have had re...
Hi all,
I am developing an app in which I have a table. In the table cell I have an imageview ( the images are displayed via url ) and a textview/webview. I start threads for each row to get the images in the
- (UITableViewCell *)tableView:(UITableView *)theTableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
method ( if image ...
I have to pass an object to an button's action... something like
[myButton addTarget:self action:@selector(sendIt:MY_OBJECT) forControlEvents:UIControlEventTouchDown];
I cannot set a variable and use that on the method because I am on a static class.
How do I do that?
thanks for any help.
...
I've been asked to edit some code for an app created in a previous iPhone SDK.
Whilst I'm aware the is deprecated in 3.0, I can't seem to get it working.
here is the code snippet I need to change, any suggestions?
- (id)initWithFrame:(CGRect)frame reuseIdentifier:(NSString *)reuseIdentifier {
if (self = [super initWithFrame:frame reus...
I understand that NSNumber is immutable, but I still have the need to change it in my app. I use it because it's an object, and therefore usable with @property (if I could, I would use float or CGFloat in a heartbeat, but sadly, I can't).
Is there any way to just overwrite the old NSNumber instance? I'm trying this:
NSNumber *zero = [[...
As far as I can tell, I can only get the entire address book, but there is no way to know which (if any) contact is the contact information for the owner of the phone, i.e. the phone # of the phone itself.
Is there any way to accomplish this? Perhaps by triangulating some data the SDK makes available?
...
I am trying to see which button was clicked on so I can preform the correct logic.
This is the code for the buttons:
UIButton *button = [[UIButton alloc] initWithFrame:CGRectMake(270, 423, 60, 60)];
[button addTarget:self action:@selector(buttonPressedAction:)
forControlEvents:UIControlEventTouchUpInside];
[button setBackgroundIma...
I have an application that has a UINavigationController that drills down to a view that looks like a card. I have on the card view a right button on the navigation bar which, when pressed, flips the view with a UIViewAnimationTransitionFlipFromRight animation to reveal the sudo back of the card. This is great and works well but when I pr...
I created a view Called ProgrammaView that appears when a row of a table is clicked.
This view has a UILabel, a UIImageView and a UITextView.
Now.
ProgrammaView's Outlets have to be changed by the parameter passed to a method of the view called iniz.
in this
image there is first the ProgrammaView.h and then the method iniz.
The prob...
I am trying to create something that uses the idea of the UIPopOverController, I mean, have that speech bubble anchor pointing to the button who triggered the method.
The problem is that I am using a UISegmentedControl...
How do I get the id of the button that was tapped on a UISegmentedControl, so I can determine its position and gene...
I'm developing an iPhone app that features a tab-bar based navigation with five tabs. Each tab contains a UITableView whose data is retrieved remotely. Ideally, I would like to use a single UIActivityIndicatorView (a subview of the window) that is started/stopped during this remote retrieval - once per tab.
Here's how I set up the spi...
Hi. I need to submit an email address with a "+" sign and validate in on server. But server receives email like "[email protected]" as "aaa [email protected]".
I send all data as POST request with following code
NSURL* url = [NSURL URLWithString:[NSString stringWithFormat:@"%@%@", url, @"/signUp"]];
NSString *post = [NSString stringWithFo...
hi
i need to countdown dates not times
how to run countdown with dates to count days in iphone sdk
...
I have a very basic data class that is subclassed from NSObject. I declare a few strings, make sure they have properties (nonatomic, copy), and synthesize them. The only method I implemented was dealloc() which releases my strings. Can any memory problems arise from just this? Are there any other methods I need to implement?
...
I am trying to develop a simple freehand-drawing app for red-marking some of my images.
Below is a method that is called from within the drawRect.
I want to ask if there is a way to avoid adding the path every time
before the path is redrawn?
Also, the way the draw method is set up, the drawing gets a bit slow and choppy after a few se...