Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Jason Espin 368 posts 1335 karma points
    Apr 23, 2014 @ 12:10
    Jason Espin
    0

    The value of parameter 'id' must be either a string or an integer

    Hi all,

    I just received the following error when trying to load one of my pages:

    The value of parameter 'id' must be either a string or an integer
    

    This makes sense to me, however I've checked all of the IDs used on the page and they are all auto-assigned ints. The code it is flagging up as incorrect is as follows:

    <span class="glyphicon glyphicon-time">&nbsp;</span><span class="timestamp">@item.CreateDate.ToString("f")</span>
    

    Any ideas why it might be doing this?

  • Antony Briggs 78 posts 103 karma points
    Apr 23, 2014 @ 12:49
    Antony Briggs
    0

    Hi Jason,

    I've seen that error when loading content - where are you populating the item variable?

  • Jason Espin 368 posts 1335 karma points
    Apr 23, 2014 @ 14:00
    Jason Espin
    100

    Sorry I tried to delete this thread as I solved the issue. I wasnt performing a check to see if an image was present before outputting it to the page. I've resolved this now by replaceing the image with a dummy image if no content is found.

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies