Move file to mapped network drive with MID Server Script Include
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-15-2013 06:18 AM
Hello,
We have a MID Server Script Include running that generates a text file. I am trying to move the generated file (via code) to a network drive that is mapped from the Windows machine the MID Server is running on after it is created. I was able to move the file to a different directory locally using the Java File object, but when I put a UNC path in as the destination directory, I am receiving a "java.io.IOException: Access is denied" error.
I am able to create/update a file in the mapped drive manually, so I know it isn't really a permission issue, but something about doing it via code, it doesn't like.
Does anybody have any advice to point me in the right direction?
Much appreciated!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-15-2013 08:28 AM
I found out the issue a few hours later. I mapped the drive with the same credentials that the MID Server service was running as, and was able to write to the directory fine.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-29-2018 10:15 AM
Greg,
I know this post was a long time ago, but I was wondering if you would be willing to share how you accomplished the script for moving the file to another drive?
Thank you
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-12-2018 02:50 AM
I would also like to know the code for this 🙂
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-03-2021 06:20 AM
I'm wondering if the Greg ever posted his solution (the MID server script include) anywhere. I'm interested in moving files off the MID and into a network directory rather than some of the SFTP solutions floating around.