Need help with Admob.

Discussion in 'iOS Development' started by bamhm182, Jun 19, 2009.

  1. bamhm182

    bamhm182 Member

    Joined:
    Mar 2, 2009
    Messages:
    544
    Likes Received:
    0
    Device:
    3G iPod touch
    I've looked and there are no threads about Admob here, and I need some help.

    The only problem that I haven't fixed is that when I put this in:

    Code:
    - (NSString *)publisherId {
    	return @"My Publisher Number";
    I get that it can't find @end.

    If I put @end before it, than it takes out the publisherId, that is the correct way to do this? I assume that I need to set @end twice, but what to I put in publisherId's section?

    EDIT: WOW! Okay, STUPID mistake on my part... I missed the }...

    EDIT 2: It still crashes on me though.

    Is this the correct way to set a Delegate?

    .h
    Code:
    @interface ViewController : UIViewController <AdMobDelegate> {
    
    .m
    Code:
    @implementation ViewController
    
    Than everything is under that, including the code from above.

    EDIT 3: I've got it to load now, however, it still isn't loading the ad... Not sure why... I'll post when I know.
  2. cocotutch

    cocotutch Community Development Team Staff Member

    Joined:
    Oct 6, 2008
    Messages:
    1,285
    Likes Received:
    117
    Device:
    5G iPod touch
    Good lord, Mail has been checking my Email for over an hour

    Please Register or Log in to view images

    I got to the stage that the Ad wouldn't show on the Device, but it always worked in the simulator, did you have Wi-Fi on?

    Lol, coz I think I know what went wrong, did you apply the view? We were up for hours last night nutting this out, jeeeez, this morning I almost swallowed the bottle of headache pills

    Please Register or Log in to view images



    CT
    ------------------double post merged------------------
    Oh lord, please. I got the final source code in the Mail (eMail), and the two videos are the same. Please tell me you remembered to change it

    Please Register or Log in to view images



    CT
  3. NolesFans

    NolesFans New Member

    Joined:
    Sep 23, 2008
    Messages:
    404
    Likes Received:
    0
    Device:
    iPod touch
    Without seeing the whole source code, it be harder for somebody else to find a problem.
  4. bamhm182

    bamhm182 Member

    Joined:
    Mar 2, 2009
    Messages:
    544
    Likes Received:
    0
    Device:
    3G iPod touch
    Like I said, I got it sorted. I eventually just went with doing it in IB, not through code. MUCH easier.

    Also, yeah, cocotutch, I was up for at least 5 hours or so after you went to bed. I think I finished and submitted it at about 2 PM here. Than I stayed up til about 5 PM.

    We already got the other part sorted. The problem was 3.0 is buggy. He had to change it from com.DrWilsonGaming.AppName to com.DrWilsonGaming.AppName15618 or some random numbers at the end so it thought it was a different app.

Share This Page