Copied to clipboard

Flag this post as spam?

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


  • Paul de Quant 403 posts 1520 karma points
    Aug 15, 2019 @ 10:40
    Paul de Quant
    0

    ExpireDate property in Umbraco 8

    Hello,

    I'm using the ContentService > GetById function and in V7 I use to be able to see the ExpiryDate, but now I can't seem to see this property in the intellisense anymore.

    Can anyone tell me where I can find this property?

    Thanks

    Paul

  • Shaishav Karnani from digitallymedia.com 354 posts 1638 karma points
    Aug 15, 2019 @ 12:20
    Shaishav Karnani from digitallymedia.com
    0

    It is ExpireDate in v8.

  • Paul de Quant 403 posts 1520 karma points
    Aug 15, 2019 @ 12:34
    Paul de Quant
    0

    I'm not seeing it in the intellisense list with the others properties such as PublishDate, Name, Level etc.

  • Magnus Eriksson 122 posts 362 karma points
    Aug 19, 2019 @ 09:06
    Magnus Eriksson
    0

    Did you sort it out? I can't find ExpireDate on IContent in V8 either? It's there in V7.

    Regards, Magnus

  • Paul de Quant 403 posts 1520 karma points
    Aug 19, 2019 @ 09:13
    Paul de Quant
    0

    Hi Magnus,

    I'm afraid not - still hoping someone will point it out. I wasn't sure if it was in the Properties collection - i'll have to check.

    Thanks

    Paul

  • Paul de Quant 403 posts 1520 karma points
    Aug 19, 2019 @ 10:09
    Paul de Quant
    100

    Hi Magnus,

    I've found something, it's not as neat but it will get the value.

    ContentSchedule.GetSchedule(ContentScheduleAction.Expire).Select(x=> x.Date).OrderByDescending(o=>o.Date).FirstOrDefault()

    Hope it helps.

    thanks

Please Sign in or register to post replies

Write your reply to:

Draft