Search Results

Search found 15682 results on 628 pages for 'iphone'.

Page 33/628 | < Previous Page | 29 30 31 32 33 34 35 36 37 38 39 40  | Next Page >

  • How to add a TabBar to NavigationController based iPhone app

    - by Alex
    I have a simple NavigationController based app. The main window shows a TableView and selecting an item loads a sub-view. I used Interface Builder for UI views. Now I want to add a TabBar to the app. Where do I put it? Do I need a TabBarController? Should it go in the MainWindow.xib, or RootViewController.xib? How do I tie it together with my NavigationController?

    Read the article

  • Setting default language for iPhone app on first run

    - by RaYell
    I'm developing an application that should support two languages: English and French. However because English translation is not done yet we want to deploy it in French only and later on add English translation later on. The problem is that I don't want to strip English language out of my code since some parts are already done, there are different NIBs for that language etc. Instead I'd just want english language to be temporary disabled in my app. What I did is I put this code as the first instruction of - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults]; [defaults setObject:[NSArray arrayWithObjects:@"fr", nil] forKey:@"AppleLanguages"]; [defaults synchronize]; It works fine except for one thing. When you launch the application for the first time after installation it's still in English. That's probably because AppleLanguages preference was not yet set for it. After I quit the application and start it again it's being displayed correctly in French. Does anyone knows a fix so that French language was applied also on the first run?

    Read the article

  • How To Make iPhone App For Multiple Firmwares

    - by Dyldo42
    With iOS4 coming out soon, I have already planned to include an iAd in a future update of an app of mine. I assume that this will make my app unusable for anyone on a firmware lower than 4.0. Is there a way to change that variables and the .xib file based on the user's firmware? Cheers.

    Read the article

  • Is any EXIF data stored within 3rd party Camera apps on the iPhone?

    - by 3rdparty
    I'm confused as to if any EXIF data is available when taking photos within 3rd party camera apps on the iPhone. My understanding is that Apple is currently not allowing any apps to save EXIF data to photos, and this is a limitation of saving to the camera roll on the phone. The last FAQ on this page indicates this, but appears to be out of date: http://www.codegoo.com/page/support I love some of the camera apps I've downloaded (Camera Genius, Best Camera, CameraBag) but don't want to continue using them if they aren't saving any/all EXIF data for the image. Anyone aware what the status of this 'limitation' is?

    Read the article

  • iPhone: error: request for member 'table' in something not a structure or union

    - by Jack Griffiths
    Hi there, When it comes to compiling my application, I get the error mentioned in the title. How would I go about remedying this error? Basically, I want to get from one table to the other. Hierarchy, navigation. NextViewController.m #import "RootViewController.h" #import "NextViewController.h" @implementation NextViewController - (void)didReceiveMemoryWarning { [super didReceiveMemoryWarning]; // Releases the view if it doesn't have a superview // Release anything that's not essential, such as cached data } - (void)dealloc { [super dealloc]; } - (IBAction) changeTable:(NSString *)str{ tblCSS.table = str; } The last line contains the error. If you need any more code, just ask. I'll amend this post with it. Cheers, Jack

    Read the article

  • iphone cocos2d sprites disappearing

    - by jer
    I've been working on a game and implementing the physics stuff with chipmunk. All was going fine on the cocos2d part until the integration with chipmunk. A bit of background: The game is a game with blocks. Levels are defined in a property list, where positions, size of the blocks, gravitational forces, etc., are all defined for each block to be shown in the level. The problem is with the blocks showing up. I have a method on my BlockLayer class which is part of my game's main scene. Upon creation of the layer, the property list is read, and all the blocks are created. The following method is called to create the blocks: - (void)createBlock:(Block*)block withAssets:(NSBundle*)assets { Sprite* sprite; switch(block.blockColour) { case kBlockColourGreen: sprite = [Sprite spriteWithFile:[assets pathForResource:@"green" ofType:@"png" inDirectory:@"Blocks"]]; break; case kBlockColourOrange: sprite = [Sprite spriteWithFile:[assets pathForResource:@"orange" ofType:@"png" inDirectory:@"Blocks"]]; break; case kBlockColourRed: sprite = [Sprite spriteWithFile:[assets pathForResource:@"red" ofType:@"png" inDirectory:@"Blocks"]]; break; case kBlockColourBlue: sprite = [Sprite spriteWithFile:[assets pathForResource:@"blue" ofType:@"png" inDirectory:@"Blocks"]]; break; } sprite.position = block.bounds.origin; [self addChild:sprite]; if(block.blockColour == kBlockColourGreen || block.blockColour == kBlockColourRed) space-gravity = cpvmult(cpv(0, 10), 1000); cpVect verts[] = { cpv(-block.bounds.size.width, -block.bounds.size.height), cpv(-block.bounds.size.width, block.bounds.size.height), cpv(block.bounds.size.width, block.bounds.size.height), cpv(block.bounds.size.width, -block.bounds.size.height) }; cpBody* blockBody = cpBodyNew([block.mass floatValue], INFINITY); blockBody-p = cpv(block.bounds.origin.x, block.bounds.origin.y); blockBody-v = cpvzero; cpSpaceAddBody(space, blockBody); cpShape* blockShape = cpPolyShapeNew(blockBody, 4, verts, cpvzero); blockShape-e = 0.9f; blockShape-u = 0.9f; blockShape-data = sprite; cpSpaceAddShape(space, blockShape); } With the above code, the sprites never show up. However, if I comment out the "cpSpaceAddBody(space, blockBody);" line, the sprites show up. The position and size of the blocks are stored in the "bounds" property of instances of the Block class, which is a CGRect. Not sure if it's important, but the orientation of the app is in landscape left, and all the coordinates are based on that orientation. Any help would be greatly appreciated.

    Read the article

  • Is it possible to accept a button tag to be in some range iphone sdk

    - by neha
    Hi all, In my application I'm doing dynamic resizing of cells and label in it depending upon the text in it. I'm adding button to cells in uitableview. I'm taking the label instance and button instance in a new label and button variable respectively and setting their frames to arrange them properly after resizing. if(cel==nil) { //some code original_label=[[UILabel alloc]init]; original_label.tag=111; //SOME MORE CODE GOES HERE original_button=[[UIButton alloc]init]; original_button.tag=222; //SOME MORE CODE GOES HERE } new_label=(UILabel *) [cell viewWithTag:111]; //This' how I'm taking the label instance on cell and below button instance on cell in new variables new_button = (UIButton * ) [cell viewWithTag:222]; Earlier I kept the tags of all the buttons on cells same, so it was easier to get button instances on cells properly and were being arranged properly. But now I want to recognize these buttons separately as I'm adding some functionality on button_click. I'm giving the buttons that are added to the cells incremental tags[1,2,3...9 and so on]. Now, how can I take these button tags in some range like[suppose 1-9]? Can anybody help? Thanks in advance.

    Read the article

  • xmlCtxtGetLastError - Iphone

    - by Raphael Kohn
    Hi, I have been programming with NSXMLParser for quite a while and lately, I came out with this error. The strangiest thing is that it only happens in debug mode. Once I load the App in Simulator and run it from Simulator (without Xcode involved), it runs fine. The code is very straight foward, it is a simple XML parsing whose contents were loaded from the web in a separated thread. Does anybody have alredy encoutered that error?? Thanks in advance.

    Read the article

  • iPhone slide view passing variables

    - by sebastyuiop
    Right, I'm trying to make an app that has a calculation that involves a stopwatch. When a button on the calculation view is clicked a stopwatch slides in from the bottom. This all works fine, the problem I can't get my head around is how to send the recorded time back to the previous controller to update a textfield. I've simplified the code and stripped out most irrelevant stuff. Many thanks. CalculationViewController.h #import <UIKit/UIKit.h> @interface CalculationViewController : UIViewController <UITableViewDelegate, UITableViewDataSource> { IBOutlet UITextField *inputTxt; } @property (nonatomic, retain) UITextField *inputTxt; - (IBAction)showTimer:(id)sender; @end CalculationViewController.m #import "CalculationViewController.h" #import "TimerViewController.h" @implementation CalculationViewController - (IBAction)showTimer:(id)sender { TimerViewController *timerView = [[TimerViewController alloc] init]; [self.navigationController presentModalViewController:timerView animated:YES]; } TimerViewController.h #import <UIKit/UIKit.h> @interface TimerViewController : UIViewController { IBOutlet UILabel *time; NSTimer *myTicker; } - (IBAction)start; - (IBAction)stop; - (IBAction)reset; - (void)showActivity; @end TimerViewController.m #import "TimerViewController.h" #import "CalculationViewController.h" @implementation TimerViewController - (IBAction)start { myTicker = [NSTimer scheduledTimerWithTimeInterval:1.0 target:self selector:@selector(showActivity) userInfo:nil repeats:YES]; } - (IBAction)stop { [myTicker invalidate]; #Update inputTxt on calculation view here [self dismissModalViewControllerAnimated:YES]; } - (IBAction)reset { time.text = @"0"; } - (void)showActivity { int currentTime = [time.text intValue]; int newTime = currentTime + 1; time.text = [NSString stringWithFormat:@"%d", newTime]; } @end

    Read the article

  • How can I add settings in the settings application for the iPhone

    - by Eytan
    I have my user preferences set to display in the system-settings application BUT I want to give them the option of adding additional settings. Specifically, the user has a group 'favorites' in the settings bundle and they then can put in the details of their three favorite contacts. However, I want to give the user the option of adding more. I know how to do this with inapp but can this be done through the settings application?

    Read the article

  • iPhone: Fetched Results Controller, don't use sections in UITableView

    - by Nic Hubbard
    I am using a fetched results controller, which, it seems wants to set up using sections in my UITableView. Well, in this case, I don't want to use sections. Which, is easy enough to set the value for numberOfSectionsInTableView: to 1. But, now I am not sure how to get the numberOfRowsInSection: to return all of the cells into one section. - (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section { // Return the number of rows in the section. id <NSFetchedResultsSectionInfo> sectionInfo = [[fetchedResultsController sections] objectAtIndex:section]; return [sectionInfo numberOfObjects]; } How can I make that method return all the cells, since I only want to use 1 section?

    Read the article

  • Custom iPhone analytic tool

    - by Ondrej
    Do you think that if I'll build my own custom analytic tool (Flurry, Pinchmedia) and I'll host that on the same server where I have my data source for the application, will Apple consider this as a thirdparty analytic tool or not? ... Problem is that Flurry and Pinch are being banned from Appstore by the newest T&C ... than I thought that I'll build an open source library that will allow anyone to have their own analytic installed on their server ... Thanks, Ondrej

    Read the article

  • iphone xml handing

    - by Mitch
    I want my app to read a XML via internet. Also I want to keep the previously download xml so next time I may not need to download again until certain hours is passed or whatever period of time according to settings. Do you recommend me to download it first and store locally before process it? Or should I process it while downloading (with libxml2 I guess)? What do you usually with apps using remote XML? Targeting 3.0 devices btw.

    Read the article

  • iphone - how to mentain the state of UIWebView ?

    - by g.revolution
    Hi, i am having a UIWebView showing and HTML page that has some checkboxes, radio buttons. My Application has tabbar controller that switches b/w two controllers. How i can maintain the current state of UIWebView. ( e.g. i have selected a checkbox and i change the tab and go to other ViewController and again come back to UIWebView. the WebView resets itself and goes to the start... i want to maintain the state of UIWebView ( all the checkboxes clicked) .. how i will do that ?? any idea ?? thanks in advance

    Read the article

  • [iphone] UIControlEventTouchDragEnter doesn't seem to work for catching a tap that slides into a con

    - by mahboudz
    I wanted to allow for a method to get called, if a finger was dragged from outside into the bounds of a control. I thought UIControlEventTouchDragEnter would do it, but it doesn't seem to. Does anyone know if there is a way to trigger an action based on a tap sliding into a control? This is what I was trying, but got no calls to my -fingerSlidIn: [aButton addTarget:self action:@selector(fingerSlidIn:withEvent: ) forControlEvents: UIControlEventTouchDragEnter]; Thanks!

    Read the article

  • iPhone: Use a view as a transparent overlay with closing button

    - by axooh
    I've got a map with three bar buttons for different markers to show up in the map. If I click on a bar button, the specific markers are shown in the map, which already works great. Now I would like to show a transparent overlay (popup window) with the description of the markers after I clicked on a bar button with a button to close the overlay again and show the markers (which are set in the background). The function of the bar button: - (IBAction)routeTwo:(id)sender { // The code for the overlay // ... // remove any annotations that exist [map removeAnnotations:map.annotations]; // Add any annotations which belongs to route 2 [map addAnnotation:[self.mapAnnotations objectAtIndex:2]]; [map addAnnotation:[self.mapAnnotations objectAtIndex:3]]; [map addAnnotation:[self.mapAnnotations objectAtIndex:4]]; [map addAnnotation:[self.mapAnnotations objectAtIndex:5]]; } I tried the following possibilities: 1. Using a modal view controller RouteDescriptionViewController *routeDescriptionView = [[RouteDescriptionViewController alloc] init]; [self presentModalViewController:routeDescriptionView animated:YES]; [routeDescriptionView release]; Works great, but the problem is: The map view in the background is not visible anymore (configuring alpha values of the modal view doesn't change anything). 2. Add RouteDescriptionView as a subview RouteDescriptionViewController *routeDescriptionView = [[RouteDescriptionViewController alloc] init]; [self.view addSubview:routeDescriptionView.view]; [routeDescriptionView release]; Works great as well, but the problem here is: I can't configure a close button on the subview to close/remove the subview (RouteDescriptionView). 3. Using UIAlertView Would work as expected, but the UIAlert is not really customizable and therefore not suitable for my needs. Any ideas how to achieve this?

    Read the article

  • iPhone: scroll view with arbitrary page/"settling" boundaries?

    - by Ben
    Hi all, I'm trying to figure out if I can get what I want out of UIScrollView through some trickery or whether I need to roll my own scroll view: I have a series of items in row that I want to scroll through. One item should always be centered in the view, but other items should be visible to either side. In other words, I want normal scrolling and edge bouncing, but I want the deceleration when the user ends a touch to naturally settle at some specified stop point. (Actually now that I think of it, this behavior is similar to coverflow in this respect.) I know UIScrollView doesn't do this out of the box, but does anyone have suggestions for how it might be made to do this, or if anyone's spotted any code that accomplishes something similar (I'm loathe to reimplement all the math for deceleration and edge bounce) Thanks!

    Read the article

  • iPhone KeyBoard Reposition

    - by NIL
    Hi all, I want to set position of keyboard when it appears. Can i set this using any API? I didn't want to use private API for that. Actually I want to display tab bar which is place d at bottom of screen.When keyboard appears then it hide the tab bar.So i want to set keyboard position at top of tab bar. Thanks in Advance.

    Read the article

  • iPhone: Core Data save Class object

    - by Nic Hubbard
    I have an entity in core data called Location. Inside this I have a few fields, such as date. But, I would also like to save a class object in it that I created called Annotation. What type of attribute would I use for this, since it is a custom class object that I created? Location (object) |__ Date |__ Annotation (MKAnnotation protocol)

    Read the article

  • Help creating custom iPhone Classes

    - by seanny94
    This should be a simple question, but I just can't seem to figure it out. I'm trying to create my own class which will provide a simpler way of playing short sounds using the AudioToolbox framework as provided by Apple. When I import these files into my project and attempt to utilize them, they just don't seem to work. I was hoping someone would shed some light on what I may be doing wrong here. simplesound.h #import <Foundation/Foundation.h> @interface simplesound : NSObject { IBOutlet UILabel *statusLabel; } @property(nonatomic, retain) UILabel *statusLabel; - (void)playSimple:(NSString *)url; @end simplesound.m #import "simplesound.h" @implementation simplesound @synthesize statusLabel; - (void)playSimple:(NSString *)url { if (url = @"vibrate") { AudioServicesPlaySystemSound(kSystemSoundID_Vibrate); statusLabel.text = @"VIBRATED!"; } else { NSString *paths = [[NSBundle mainBundle] resourcePath]; NSString *audioF1ile = [paths stringByAppendingPathComponent:url]; NSURL *audioURL = [NSURL fileURLWithPath:audioFile isDirectory:NO]; SystemSoundID mySSID; OSStatus error = AudioServicesCreateSystemSoundID ((CFURLRef)audioURL,&mySSID); AudioServicesAddSystemSoundCompletion(mySSID,NULL,NULL,simpleSoundDone,NULL); if (error) { statusLabel.text = [NSString stringWithFormat:@"Error: %d",error]; } else { AudioServicesPlaySystemSound(mySSID); } } static void simpleSoundDone (SystemSoundID mySSID, void *args) { AudioServicesDisposeSystemSoundID (mySSID); } } - (void)dealloc { [url release]; } @end Does anyone see what I'm trying to accomplish here? Does anyone know how to remedy this code that is supposedly wrong?

    Read the article

  • iPhone SDK Nested For Loop performance

    - by Skeep
    Hi All, I have a NSArray of string id and a NSDictionary of NSDictionary objects. I am currently looping through the string id array to match the id value in the NSDictionary. There are around 200 NSDictionary objects and only 5 or so string ID. My current code is such: for (NSString *Str in aArr) { for (NSDictionary *a in apArr) { if ([a objectForKey:@"id"] == Str) { NSLog(@"Found!"); } } } The performance of the above code is really slow and I was wondering if there is a better way to do this?

    Read the article

< Previous Page | 29 30 31 32 33 34 35 36 37 38 39 40  | Next Page >