0

I have a class, EmailSendJob, that implements IJob and I need to get the path to the App_Data folder in my web project from the Execute(IJobExecutionContext context) method of the EmailSendJob class. Can anyone tell me how to do this?

Damien_The_Unbeliever
  • 234,701
  • 27
  • 340
  • 448
COBOL
  • 1,031
  • 8
  • 16
  • 32

1 Answers1

1

Probably want something like:

var appDataPath = (string)AppDomain.CurrentDomain.GetData("DataDirectory");

(should work for ASP.Net or Local Applications)

Erik Philips
  • 53,428
  • 11
  • 128
  • 150