HI @Anonymous ,
I will answer both questions. If you wanted the hard-code the date, use this syntax (replace with actual date)
Set(vExpiry,DateValue("mm/dd/yyyy"))
You could do this at App OnStart.
If you wanted to put this on a single-line SharePoint reference list (I do a few of these) assuming it is called RefList, the ID is 1 and the field is RefDate, you would do the same with a Lookup
Set(
vExpiry,
Lookup(
RefList,
ID=1,
RefDate
)
)
To answer your second question - this would give the user a View form on the current record, otherwise a New form if on or before the expiry date.
If(
vExpiry<Today(),
ViewForm(YourFormName),
NewForm(YourFormName)
)
If the form is on another screen, add Navigate to this.
Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.