I'm trying to save a timestamp into a constant at the beginning of a program's execution to be used throughout the program. For example:
Const TIME_STAMP = Format(Now(), "hhmm")
However, this code generates a compiler error - "Constant expression is required." Does that mean all constants in VB .NET have to contain flat, static, hard-coded data? I know that it's possible to initialize a constant with a dynamic value in other languages (such as Java) - what makes it a constant is that after the initial assignment you can no longer change it. Is there an equivalent in VB .NET?