Skip navigation
Ph Brouard
Currently Being Moderated

Virtual Directory for file is not working with my AMS 5

Jul 25, 2013 3:20 AM

Tags: #file #virtual #directory

Hello, I've read discussions about issues with File.copyTo. But I have still a problem. I am upgrading my server from FMS 3.5 to AMS 5.0. In the conf/Server.xml I changed the option for Virtual Directory for file, to enable it :


<VirtualDirectoryForFile enable="true"></VirtualDirectoryForFile>


In my Application.xml, I  have this :



     <FileObject override="no">





Then I tried this example from documentation ( 1e63e3d11a11afc95e-7eacSSASLR.2.3.html),, I tried this in my .asc file :



var logFile = new File("log.txt");

if(!logFile.exists){"text", "append");

     logFile.write("something", "somethingElse")



At this point, it's working, when I run the scripts, I've got new log.txt file in my Application folder (where AMS is installed).

But if I change the script like this :


var logFile = new File("/DataFlash/log.txt");      


The, I get an error :

Error: File operation write failed.


It seems that my Virtual Directory for file is not working.

I've got something working with a virtual directory for stream, but it's KO for file ! I don't understand why.


In my vhost configuration Application.xml, there is nothing special.


I have also a false return when I try :


myDir = new File("/DataFlash");



D:\DataFlash is settled why read and write permissions.


I don't want to use folders in install path (C:\Program...).

Can anyone help me to understand what is wrong with my Virtual Directory for file ?



  • Currently Being Moderated
    Jul 25, 2013 12:15 PM   in reply to Ph Brouard

    You cannot set virtual directories outside of the application root.

    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points