Search

Index

Revindex Task Scheduler

Write file (Razor C#)

Last updated on 2015-04-17 1 mins. to read

To write text to a file, you can simply use the following Razor (C#) statements. Please note your IIS host must be allowed to write to the specified folder:

@{
    System.IO.File.WriteAllText("C:\\MyFolder\\MyFile.txt", "Some text");
}

Comments


Powered by Revindex Wiki