Page 1 of 1

cocoa programming help

Posted: Fri Jul 04, 2008 5:47 pm
by Slapzy
im trying to write an application, but i keep getting an error at this point in the build. (x = error line)

Code: Select all

{
x   –index;
    if (index < 0) {
         index = [iconImages count] - 1;
    }
    [self displayIconAtIndex:index];        
}
can someone help me find whats wrong here?

Posted: Fri Jul 04, 2008 5:55 pm
by P!ckoff
Use:

Code: Select all

 [code]&
[/code]

So the emoticons wont show up.

Posted: Fri Jul 04, 2008 5:56 pm
by Slapzy
thanks :P i knew that, i just forgot.

Posted: Fri Jul 04, 2008 6:15 pm
by Excend
or... you could just disable smilies >.>

Posted: Fri Jul 04, 2008 8:16 pm
by P!ckoff
WhatEVER! Sorry, I'm a designer, not a programmer. Want to be, but am not nerdy enough yet. Hope you get some help, and also, there HAS to be a support forum for mac programmers out there...

Posted: Fri Jul 04, 2008 9:21 pm
by Slapzy
P!ckoff wrote:WhatEVER! Sorry, I'm a designer, not a programmer. Want to be, but am not nerdy enough yet. Hope you get some help, and also, there HAS to be a support forum for mac programmers out there...
same here, trying to be, but just not geeky enough to understand it all :/

Posted: Sat Jul 05, 2008 6:18 am
by Excend
i only program with javascript and because my mom makes me O.o... but i get paid for it :D

Posted: Sat Jul 05, 2008 7:15 am
by Dirk Gently
can you explain what you are trying to do exactly?

Posted: Sat Jul 05, 2008 7:39 am
by Excend
it looks like he is trying to make an icon appear O.o

Re: cocoa programming help

Posted: Sat Jul 05, 2008 8:41 am
by nil
Slappey wrote:im trying to write an application, but i keep getting an error at this point in the build. (x = error line)

Code: Select all

{
x   –index;
    if (index < 0) {
         index = [iconImages count] - 1;
    }
    [self displayIconAtIndex:index];        
}
can someone help me find whats wrong here?
Generally, when asking people for help to see what's wrong, you want to tell us the exact error message it spits out.

If you haven't figured it out yet, it's a syntax error at line x. You probably meant:

Code: Select all

--index;

Posted: Sat Jul 05, 2008 1:16 pm
by Slapzy
i fixed it, thanks, and yeah it was

Code: Select all

--index;