You can do this with the help of attributes.
In VC++ the enviromnent ( compiler ) specified __DATE__ and __TIME__, that
is why in the compiled source was required data.
I see 2 ways how can you achieve same result
1) write attribute class that will hold the date. The targe of this
attribute will be the assembly you're building ( watch for AssemblyInfo.cs,
when using wizard ). Minus of this way is that you'll have to specify
manually build date.
2) You can use CompilerServices. You generate source code that will contain
the applied attribute with correct date value. CompilerServices will let you
build your assembly manually thus you will mimic the behavior of the C++
compiler...
--
Vadym Stetsyak aka Vadmyst
http://vadmyst.blogspot.com
"Jesper" <Je****@discussions.microsoft.com> wrote in message
news:EE**********************************@microsof t.com...
Hi,
In c++ ( I do no longer remember exactly how) I used some compiler
predefined macro to insert the date and time of compilation into a string.
How is this done in c#
In c++ it could have looked something like this
wchar_t *ptr= __DATE__;