I use AppCode to tweak the code I've written in XCode. AppCode does awesome code inspections, and tells you where things can be improved.
One of the frequent inspections I come across points out that [SomeObjCFrameworkClass objectAtIndex] is…
I have an NSString that points to a URL, something like this:
https://.../uploads/video/video_file/115/spin_37.mp4
I want to get the filename in my iOS app from the NSString (in this example, spin_37.mp4)
I'm trying the following:
NSUInteger…
I made a custom UITextField with an additional user defined runtime attribute validRange, which I can set in the storyboard view.
I use this property to check in the EndEditing method to validate the new set text.
I works all fine, till I had to set…
I have a subclass of NSObject. In this class I have an NSUInteger declared like this:
@interface Deck : NSObject
- (id)initDecks:(NSUInteger)decks;
- (Card *)drawCard;
@property (nonatomic, assign) NSUInteger drawnCards;
In my implementation…
I've been testing my app on the simulator and device. There are labels that show NSIntegers and I've formatted them as:
[NSString stringWithFormat:@"%lu", (unsigned long)_qty]
This works. However, when I build my app for TestFlight, these labels…
Hi I get this warning when using %lu:
"format specifies type unsigned long but the argument has type unsigned int."
then when i replace to %u: the warning changes to:
"format specifies type unsigned int but the argument has type unsigned long."
here…
index is a NSUInteger on both my parent and child view controller. But when I try to pass the NSUInteger value for index I get a warning on this line: controller.index = index; saying "incompatible integer to pointer conversion assigning to…
I want to declare a NSInteger variable in my ViewController, but I get an error.
In my ViewController.h I have
@interface MainViewController : UIViewController{
NSInteger currentSection;
//Other stuff
}
@property (assign,nonatomic)…