Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums JavaScript Difficulties with objects

  • This topic is empty.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #196039
    shaneisme
    Participant

    I hope I’m just missing something after working all day today…

    http://codepen.io/drainpip/pen/QwQeOd?editors=001

    Why is arrayItems.programID coming back undefined if I can see the keys and the object?

    cc @traq (sorry)

    #196049
    Ilan Firsov
    Participant

    That is because the ProgramID key in the arrayItem object has a capital P so you need to use
    console.log(arrayItem.ProgramID);
    instead of
    console.log(arrayItem.programID);

    #196050
    shaneisme
    Participant

    Holy crap – I knew I was overlooking something, thanks a lot.

    Note to self, don’t code for 14 hours straight any more, you’re too old…

    #196123
    shaneisme
    Participant

    Yeah I’d like to say I didn’t spend 2 hours frustrated with it, but I did. I always get caught up on things that are so simple, they’re day one of learning to code bugs…

    At least I get paid for the “difficult” part haha

Viewing 4 posts - 1 through 4 (of 4 total)
  • The forum ‘JavaScript’ is closed to new topics and replies.