Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Warning for license expiration

    Hi there,

    We run Stata in a shared server environment and are surprised every year by the sudden annual expiration of Stata. Yes, I could set a calendar event for 360 days from today but I am wondering if Stata offers any solutions. Is there an option or work-around that would lead to Stata giving license expiration warnings 1 or 2 weeks in advance?

    Thanks,

    Kyle

  • #2
    Don't you see this expiry date every time you start up Stata? You could also type -about- to see it.

    A possible workaround is to put some code into your -profile.do- or similar that shows a warning within X days of the expiry. Since I don't see the information returned from -about-, the easiest way is to hard-code a solution, and update it once a year.

    Code:
    local expires_soon = ( td(14may2023) - today() ) < 14
    if `expires_soon' {
      di as err "Warning: Stata license will expire within 2 weeks."
    }

    Comment

    Working...
    X