These forums are now Read Only. If you have an Acrobat question, ask questions and get help from one of our experts.

How to use FSO(FileSystemObject) in acrobat javascript?

gavin2u
Registered: Jul 3 2009
Posts: 76
Answered

Okay, so here is my problem:

I wanna retrieve the file name list from a HardDisk folder.

After a while of google, I am aware that FileSystemObject could help to achieve what I what.

You see, how could I use fso in my acrobat javascrip?

Any feedback is appreciated.

Regards,

- gavin

My Product Information:
Acrobat Pro 9.0, Windows
gavin2u
Registered: Jul 3 2009
Posts: 76
any ideas or other methods?

Thanks in advance. :D
try67
Expert
Registered: Oct 30 2008
Posts: 2398
It's a VB object, not a JS object. You can't access the file system in this way from within Acrobat.

- AcrobatUsers Community Expert - Contact me personally at try6767 [at] gmail [dot] com
Check out my custom-made scripts website: http://try67.blogspot.com

gavin2u
Registered: Jul 3 2009
Posts: 76
Thanks for your quick reply. :)

try67 wrote:
It's a VB object, not a JS object. You can't access the file system in this way from within Acrobat.
javascript also have fso, check this instruction plz:

http://www.webreference.com/js/column71
try67
Expert
Registered: Oct 30 2008
Posts: 2398
This reference is about the version of JS that runs in browsers, which is not the same as the version that runs in Acrobat.

- AcrobatUsers Community Expert - Contact me personally at try6767 [at] gmail [dot] com
Check out my custom-made scripts website: http://try67.blogspot.com

gavin2u
Registered: Jul 3 2009
Posts: 76
try67 wrote:
This reference is about the version of JS that runs in browsers, which is not the same as the version that runs in Acrobat.
mmm, I see, acrobat javascript is part of EMACJavascript.

Thanks, try67. By the way, how could get a file name list according a certain folder?

Is it possible?
try67
Expert
Registered: Oct 30 2008
Posts: 2398
Only way I know of (in Acrobat with JS) is if the folder is scanned in a batch process.
That way you can save all the names of the files (which are opened) into an array and work with that.

- AcrobatUsers Community Expert - Contact me personally at try6767 [at] gmail [dot] com
Check out my custom-made scripts website: http://try67.blogspot.com

gavin2u
Registered: Jul 3 2009
Posts: 76
try67 wrote:
Only way I know of (in Acrobat with JS) is if the folder is scanned in a batch process.
That way you can save all the names of the files (which are opened) into an array and work with that.
That's right.

However, I have a range of pdf with various file name type, not like an array :(

before processing, i'd like to retrieve their file name in acrobat javascript.