Hi Programmers,
I have this code:
FIELD Comments := @Left (@Text(@Today); “2018”) + "18: " + @Right(@Name([CN];@UserName); " ") + ": ";
…But would like to have the “2018” and "18: " automatically use the current year instead of having to change this code for every new year. I’m sure this is ridiculously easy but I’m not a programmer. Please let me know what the code needs to be.
Thanks, Paul
Subject: Getting todays Year
Hi Paul
Try
FIELD Comments := @Text(@Year(@Today)) + "18: " + @Right(@Name([CN];@UserName); " ") + ": ";
Will give you
"201818: Gaschke: "
But is that really what you want ?
Kind Regards
Simon
PS, I suggest putting your question up on StackOverflow for a faster response.
Subject: No
He’s just after the date, but with a two year date format vs 4.
So
9/10/18 : Gaschke
Personally, I would always use the four digit date, it’s not like systems are running low on memory.