Hi
I am developing a game in which I am using Landscape mode I have total 4 view.
2 views are properly coming in Landscape mode. But in third view I have UITable and Navigation bar. I can able to rotate table in landscape mode but not able to transform Navigation bar and Navigation controller. Navigation bar and Navigation Controller al...
Sorry if this is a broad question, but other than Objective-C, Cocoa, and OpenGL ES, what technologies or concepts would you suggest I read up on before writing a game for the iPhone? I'm a beginning game developer and need all the help I can get :)
...
I am having a problem with a Core Data model in Cocoa. It's probably a fairly basic problem. A section of my Core Data model is shown below. Given the value of a cell property in the OutputCell entity, I want to return the relevant HistogramBar.
I'm using the following Predicate but it just returns an empty array. I've managed to ge...
I want to add some marks to separate some strings.
How to add a char to a string?
e.g. add '\x01' to "Hello", add '\x02' before "World" and add '\x03' after "World".
So I can create a string "\x01 Hello \x02 World \x03" which has some separate marks.
...
I have the following method
-(NSMutableArray *) getPaises {
NSMutableArray * paises;
paises = [[NSMutableArray alloc] init];
while( get new row ) {
NSString *aPais = [NSString stringWithUTF8String:(char *)sqlite3_column_text(compiledStatement, 0)];
[paises addObject:aPais];
}
return paises;
}...
I need to return a NSString from a function:
NSString myfunc ( int x )
{
// do something with x
NSString* myString = [NSString string];
myString = @"MYDATA";
// NSLog(myString);
return *myString;
}
So, I call this function and get *myString. Is that a pointer to the data? How can I get to the data "MYDATA...
Can someone point out what is the difference?
And what for do we actually pay so much money, when supporting the iPhone with our hard work?
Is it right that I have to have the Enterprise Membership (299 USD), when I want to sell Apps for money? Or can I also sell Apps when I "only" have the cheaper Standard Membership (99 USD)?
Is the...
Hi People :)
I have from 4 up to 20 variables that differ in size.
They are all of type float and number values.
Is there an easy way to find the smallest value among them and assign it to a variable?
Thanks
...
How to create richtextview, that show URLs and Images and handle touches?
...
Hi all,
I have a simple method in my code which looks like the following:
- (BOOL)isFirstTimeLogin
{
NSString *t_gName =
[NSString stringWithFormat:@"%@", [[NSUserDefaults standardUserDefaults] objectForKey:kGroupIdentifierKey]];
if ([t_gName isEqualToString:@""] || t_gName == nil) {
DLog(@"LoginViewController, m:::isFi...
So, I saw this:
error:(NSError **)error
in the apple doc's. Why two stars? What is the significance?
...
I've figured out how to use the NSBezierPath class to draw shapes in the drawRect function of my custom view class, however I can't seem to figure out how to draw text. The following code is what I have so far for drawing the text (located in the drawRect function):
NSText *text = [NSText new];
[text setTextColor: [NSColor yellowColor]]...
I add a PickerView to one of my views in an app, but its size is too small(in height). I find that I cannot drag to make it "longer". How to change its size then?
...
Hi,
Is there any way to bundle a certificate in my application - and then use that to perform HTTP GET/POST using a NSURLRequest?
I.e. the certificate should not be used for other HTTP traffic on the device, only by my application.
Cheers
...
First off; I'm a COMPLETE newbie at Cocoa, so please bare with me for asking what I am sure is an inane and utter newbish question.
My situation is as follows: I want to expand on the functionality of NSTextField. AMong the things I want to achieve is:
Changing the look and feel of the caret.
Detecting when the text reaches a certain...
I'm trying to do a simple thing; read an image from the internet, save it to the app's documents directory on the iphone, and read it back from that file so that i can do other things with it later. Writing the file works fine but when i try to read it back i get an EXC_BAD_ACCESS error in GDB that i have no idea how to resolve. Here i...
I have the following Obj C function that works properly:
NSString* myfunc( int x )
{
NSString *myString = @"MYDATA";
return myString;
}
However if I add code to update a UIImage the compile fails with image1 being unknown. image1 is valid: it's set up in the .h, synthesized and that exact line of code works
in a m...
I've change a c-style function to an objective-c method. As a method, how do i use it?
NSString* myfunc( int x )
is now:
- (NSString *)myFuncWithParam:(int)x
c code: myString = myfunc(x); // works
obj-c code: myString = myFuncWithParam(x); // fails to compile.
From one of the answers: myString = [object myF...
I'm just starting to learn Objective-C using GNUstep on Windows and I'm wondering what type of debugging options are available? I'm using make to compile and link the code, but once I run the app there doesn't appear to be a way to step through code and inspect variables, the call stack or whatever. Now this isn't the end of the world if...
I've been using c-style functions, but I just learned they can't see instance variables. So I was advised to convert them to methods.
NSString* myfunc ( int x )
becomes:
- (NSString *)myfunc:(int)x
and
myString = myfunc(x);
becomes
myString = [myString myfunc: x];
??
This compiles with ominou...