Search Results

Search found 8409 results on 337 pages for 'itunes sdk'.

Page 168/337 | < Previous Page | 164 165 166 167 168 169 170 171 172 173 174 175  | Next Page >

  • Common, reusable iPhone-App configuration screen

    - by Janey
    I'm writing code that will allow my iphone-app to have a "configuration page". A grouped, scrolling, UITableView... with cells that contain the needed textFields, switches, sliders, etc. It is an ENOURMOUS amount of code. Is there an easier way? Is there a way I could create a simple text-file, contain all my desired design choices and have my (reusable) code build the TableView for me? Or... can I just do the whole thing quicker/easier in Interface Builder instead of code?

    Read the article

  • Possibility of a custom Contacts field with a set list of values and Contacts lookup performance

    - by areyling
    I'm pretty sure it's not viable to do what I'd like to based on some initial research, but I figured it couldn't hurt to ask the community of experts here in case someone knows a way. I'd like to create a custom field for contacts that the user is able to edit from the main Contacts app; however, the user should only be allowed to select from a list of four specific values. A short list of string values would be ideal, but an int with a min/max range would suffice. I'm interested in knowing if it's possible either way, but also wondering if it make sense to go this route performance wise. More specifically, would it be better to look up a contact (based on a phone number) each time a call or SMS message is received or better to store my own set of data (consisting of name, numbers, and the custom field) and just syncing contact info in a thread every so often? Or syncing contacts the first time the app is run and then registering for changes using ContentObserver? Here is a similar question with an answer that explains how to add a custom field to a contact. Thanks in advance.

    Read the article

  • drawRect is not refreshing the screen

    - by coure06
    I have this code in my drawRect method float aValue = .0167f; float fValue = 20; for(int i=1; i<=6; i++) { CGContextSelectFont(context, "Arial", fValue, kCGEncodingMacRoman); CGContextSetCharacterSpacing(context, 0); CGContextSetTextDrawingMode(context, kCGTextFill); NSString *hString = [[NSString alloc] initWithFormat:@"%i",i]; CGContextSetRGBFillColor(context, 1, 1, 1, aValue); CGContextShowTextAtPoint(context, i*25, i*16, [hString UTF8String], [hString length]); aValue += 0.167; fValue += 1; } I am calling a method using NSTimer like this staticTimer = [NSTimer scheduledTimerWithTimeInterval:1.0 target:self selector:@selector(refreshUIView) userInfo:nil repeats:YES]; here is the refreshUIView -(void)refreshUIView { [self setNeedsDisplay]; } Problem is that drawRect is not clearing the screen, its just over writing what have been written last time on screen.

    Read the article

  • How to rotate a UIImageView?

    - by jkally
    It's quite frustrating not to be able to do such a simple task: I have an "app" with a single viewcontroller, and in it a single UIImageView, that's initialized to a specific image at potrtait mode. Now when the iPhone gets roteated to landscape mode and the shouldAutorotateToInterfaceOrientation event fires, at which I return YES, my resulting UIImageView looks totally screwed up: either the image is stretched so to fill landscape mode frame (which looks ridiculuous of course) or the top and bottom of the image are cropped. How can I have my UIImageview and the contained image handle the device rotation gracefully, and display normal looking image at landscape mode as well?

    Read the article

  • UITableViewCell Problem....

    - by balu
    Hi friends... i am creating a Custom reusable UITableViewCell with Three labels and one imageView,and i am removing them in cell's dealloc method... all is working fine but the problem is the text in cell getting Dark while selected... it and it is kind of overlapping on each other help me to avoid that problem... - (id)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier { if (self = [super initWithStyle:style reuseIdentifier:reuseIdentifier]) { NSLog(@"Address for cel called"); NameLbl = [[UILabel alloc] initWithFrame:CGRectMake(5,5,140,20)]; [self.contentView addSubview:NameLbl]; NameLbl.font =[UIFont fontWithName:@"Times New Roman" size:15]; NameLbl.font = [UIFont boldSystemFontOfSize:15]; NameLbl.opaque=YES; NameLbl.tag = 1001; AddressLbl = [[UILabel alloc] initWithFrame:CGRectMake(5,25,140,20)]; [self.contentView addSubview:AddressLbl]; AddressLbl.font =[UIFont fontWithName:@"Times New Roman" size:15]; AddressLbl.opaque=YES; AddressLbl.tag = 1002; CityStateZipLbl = [[UILabel alloc] initWithFrame:CGRectMake(5,50,150,20)]; [self.contentView addSubview:CityStateZipLbl]; CityStateZipLbl.opaque=YES; CityStateZipLbl.tag = 1003; CityStateZipLbl.font =[UIFont fontWithName:@"Times New Roman" size:15]; } return self; } - (void)dealloc { [CityStateZipLbl release]; [NameLbl release]; [AddressLbl release]; [super dealloc]; }

    Read the article

  • Reverse geocode street name and city as text

    - by Taylor Satula
    Hello, I have been having some trouble finding a good way to output just the street name and city as text (Infinite Loop, Cupertino shown here) that can be displayed in my iPhone app. This needs to be able to dynamically change as you change streets and city. I don't have the slightest idea of how to do this, I hope someone can help. I have attached a very rough image of what I am trying to acheave. I have found this (http://code.google.com/apis/maps/documentation/javascript/services.html#Geocoding) for google maps about how to reverse geocode using javascript, but what I do not understand is how this would be done in a iPhone development setting. I work in web design and I see how it would be done in HTML but I am very new to iPhone development and don't have the slightest clue of how it would be done here. If someone could spell out how to do this I would be extremely grateful. I cannot seem to find what I am looking for by searching Google. Reference picture: http://www.threepixeldrift.com/images/deep-storage/reversegeocodeiphoneapp.jpg

    Read the article

  • How to set a dialog themed activity width to screen width?

    - by Pentium10
    I am followin the method described here to create an EditText input activity. But the view doesn't fill the width of the screen. How can I tell to fit the screen width? <activity android:name="TextEntryActivity" android:label="My Activity" android:theme="@android:style/Theme.Dialog"/> - <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:orientation="vertical" android:gravity="right" android:layout_height="wrap_content"> <EditText android:text="@+id/txtValue" android:id="@+id/txtValue" android:layout_width="fill_parent" android:layout_height="wrap_content"></EditText> <Button android:text="Done" android:id="@+id/btnDone" android:layout_width="wrap_content" android:layout_height="wrap_content"></Button> </LinearLayout>

    Read the article

  • Another warning question: "Incompatible intiger to pointer conversion assigning to 'int *' from 'int'"

    - by Preston
    I have yet another pesky warning I would like gone. Basically, I have an int declared like this: @property (nonatomic, assign) int *myInt; and set like this: myInt = 0;. It is also synthesized in the implementation file. I am getting a warning on the line where I set the int's value and it says "Incompatible intiger to pointer conversion assigning to 'int *' from 'int'." What should I do to fix this?

    Read the article

  • Press a Button and open a URL in another ViewController

    - by Dennis Borup Jakobsen
    I am trying to learn Xcode by making a simple app. But I been looking on the net for hours (days) and I cant figure it out how I make a button that open a UIWebView in another ViewController :S first let me show you some code that I have ready: I have a few Buttons om my main Storyboard that each are title some country codes like UK, CA and DK. When I press one of those Buttons I have an IBAction like this: - (IBAction)ButtonPressed:(UIButton *)sender { // Google button pressed NSURL* allURLS; if([sender.titleLabel.text isEqualToString:@"DK"]) { // Create URL obj allURLS = [NSURL URLWithString:@"http://google.dk"]; }else if([sender.titleLabel.text isEqualToString:@"US"]) { allURLS = [NSURL URLWithString:@"http://google.com"]; }else if([sender.titleLabel.text isEqualToString:@"CA"]) { allURLS = [NSURL URLWithString:@"http://google.ca"]; } NSURLRequest* req = [NSURLRequest requestWithURL:allURLS]; [myWebView loadRequest:req]; } How do I make this open UIWebview on my other Viewcontroller named myWebView? please help a lost man :D

    Read the article

  • How to smooth the edge of a zig-zag line?

    - by Horace Ho
    Currently I draw a zig-zap line by CGContextMoveToPoint, CGContextAddLineToPoint, and CGContextStrokePath, following touchesMoved events. How can I smooth the edges of the line? Such that when the user draw a circle-like shape, the circle can be more round'ed. The GLPaint example use OpenGL, is that the only way to do it?

    Read the article

  • Simple Iphone XML Example

    - by dub
    Hi, I a bit overwhelmed with all of the sample code I've seen on the apple dev site. I'm looking for a simple example to show me how to load an xml file from a server into iphone. I would like to read url's from this xml file and load an image.

    Read the article

  • Why does the token returned by LogonUser() in Win x64 not belong to LOCAL group?

    - by edwinbs
    Hi, I have a piece of code that calls LogonUser() followed by CreateProcessAsUser(). In Win32, the resulting process belongs to a user (say, TESTDOMAIN\user1) who belongs to the LOCAL group. However, in x64, the process owner does not belong to LOCAL. The owner still belongs to all other groups (Authenticated Users, Everyone, etc.) Does anyone know if this is a documented behavior change? Or am I supposed to put some special flag in x64 when calling LogonUser()? Thanks.

    Read the article

  • services \ remote service

    - by Moshik
    Hi, sorry for a newbie question.. but "Service" by it's defenision meaning the same as "Remote service" in Android? and if not, what is the diffrence between them? thanks, moshik.

    Read the article

  • UINavigationController crashes after pushing 3 views onto stack

    - by joec
    I have a navigation controller, which has the following structure: Category Item Item Detail I can choose a category, and then choose an item to see its details. I can do this twice, i.e. go Back to the list of items and select another item. If i try this a third time, the app crashes, I get objc_msgSend in stack but thats all. But, instead of choosing another item, i go to the list of categories, and choose a different category, I can select two items in that category, before it crashes also. What would be causing this? Thanks

    Read the article

  • EASY: How does one release memory correctly in the attached C array?

    - by Tricky
    Hi, I'm just trying to work out why the following code is leaking memory and I have a funny feeling that i'm not releasing the array memory correctly. This is a C function in a wider objective-c app and I'm not native to C... i've tried just using free() on the array, but have a feeling this isn't the whole story... Could someone have a look and see what I'm missing here. Thanks! CFIndex theNumberOfSettings = 3; CTParagraphStyleSetting theSettings[3] = { {kCTParagraphStyleSpecifierAlignment, sizeof(CTTextAlignment), &alignment}, {kCTParagraphStyleSpecifierLineSpacing, sizeof(lineSpacing), &lineSpacing}, {kCTParagraphStyleSpecifierHeadIndent, sizeof(headIndent), &headIndent} }; CTParagraphStyleRef theParagraphRef = CTParagraphStyleCreate(theSettings, theNumberOfSettings); CFAttributedStringSetAttribute(attrString, CFRangeMake(0, CFAttributedStringGetLength(attrString)-1), kCTParagraphStyleAttributeName, theParagraphRef); CFRelease(theParagraphRef); free(theSettings);

    Read the article

  • How can I consolidate deferred/delayed calls in Objective-C ?

    - by thrusty
    I'd like to ensure that certain maintenance tasks are executed "eventually". For example, after I detect that some resources might no longer be used in a cache, I might call: [self performSelector:@selector(cleanupCache) withObject:nil afterDelay:0.5]; However, there might be numerous places where I detect this, and I don't want to be calling cleanupCache continuously. I'd like to consolidate multiple calls to cleanupCache so that we only periodically get ONE call to cleanupCache. Here's what I've come up with do to this-- is this the best way? [NSObject cancelPreviousPerformRequestsWithTarget:self selector:@selector(cleanupCache) object:nil]; [self performSelector:@selector(cleanupCache) withObject:nil afterDelay:0.5];

    Read the article

  • how to show video or movie file into UIImagePickerController?

    - by rakesh-bhatt99
    I am using UIImagePickerController that gives user to be able select an existing photo or use the camera to take an image at that time. And i can show that image in my application with UIImageView. Now i want to use this ability for movies also. But i couldn't find any way to show the selected movie as an image in my app, just like the Photos app. as you know you can see photos and movies in the same list.

    Read the article

  • UITextView disabling text selection

    - by dizy
    I'm having a hard time getting the UITextView to disable the selecting of the text. I've tried: canCancelContentTouches = YES; I've tried subclassing and overwriting: - (BOOL)canPerformAction:(SEL)action withSender:(id)sender (But that gets called only After the selection) - (BOOL)touchesShouldCancelInContentView:(UIView *)view; (I don't see that getting fired at all) - (BOOL)touchesShouldBegin:(NSSet *)touches withEvent:(UIEvent *)event inContentView:(UIView *)view; (I don't see that getting fired either) What am I missing ?

    Read the article

< Previous Page | 164 165 166 167 168 169 170 171 172 173 174 175  | Next Page >