Skip to content

"Unable to compile template: 4uqjvolp.0oz(5,186): error CS0103: The name 'DateTime' does not exist in the current context" #119

Answered by americanslon
americanslon asked this question in Q&A
Discussion options

You must be logged in to vote

Pull my hair for two hours, post here and literally 5 minutes later get an idea for something to try and it turns out to be the problem,

For the next weary traveler

Code from the imported assemblies has to be fully qualified

DateTime (proof assembly import working): @DateTime.Now
to
DateTime (proof assembly import working): @System.DateTime.Now

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@adoconnection
Comment options

@americanslon
Comment options

@adoconnection
Comment options

Answer selected by americanslon
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants