Automic Workload Automation

Expand all | Collapse all

List of files in html or txt or doc

  • 1.  List of files in html or txt or doc

    Posted 01-19-2019 11:36 PM

    Hello.

    I need to show result of script below as external txt or doc or html with result only:

     

    :SET &date# = SYS_DATE("YYYYMMDD")
    :SET &prevdate# = sub_days("YYYYMMDD:&date#", 1)
    dir d:\temp\test*_&date#_*.txt
    dir d:\test\test*_&prevdate#_*.txt

     

    Internal job report show (extract):

     

    d:\>dir d:\temp\test*_20190120_*.txt
     Volume in drive D is New Volume
     Volume Serial Number is 0A15-AB14

     

     Directory of d:\temp

     

    2019-01-20  04:21                 0 test2_20190120_1234.txt
    2019-01-20  04:21                 0 test_20190120_1234.txt
                   2 File(s)              0 bytes
                   0 Dir(s)  370?192?699?392 bytes free

     

    d:\>dir d:\test\test*_20190119_*.txt
     Volume in drive D is New Volume
     Volume Serial Number is 0A15-AB14

     

     Directory of d:\test

     

    2019-01-20  04:21                 0 test3_20190119_1234.txt
    2019-01-20  04:21                 0 test4_20190119_1234.txt
                   2 File(s)              0 bytes
                   0 Dir(s)  370?192?699?392 bytes free

     

    I need only directory and file names. Prefered output view is notepad txt, word doc or blank html page. It can be save as file to open by user or pop as additional report with data show like this:

     

    d:\temp\

    test2_20190120_1234.txt
    test_20190120_1234.txt

    d:\>dir d:\temp\test_20190120_*.txt   Volume in drive D is New Volume  Volume Serial Number is 0A15-AB14   Directory of d:\temp  2019-01-20  04:21                 0 test_20190120_1234.txt                1 File(s)              0 bytes                0 Dir(s)  370?192?928?768 bytes free  d:\>dir d:\temp\test2_20190120_*.txt   Volume in drive D is New Volume  Volume Serial Number is 0A15-AB14   Directory of d:\temp  2019-01-20  04:21                 0 test2_20190120_1234.txt                1 File(s)              0 bytes                0 Dir(s)  370?192?928?768 bytes free

     

    d:\test\

    test3_20190119_1234.txt
    test4_20190119_1234.txt

     

    Thaks for any help

    Regards

    Szymon



  • 2.  Re: List of files in html or txt or doc

    Posted 01-21-2019 05:22 AM


  • 3.  Re: List of files in html or txt or doc

    Posted 01-22-2019 02:26 PM

    I have used :WRITE_PROCESS() to write various files from a UC4 script.

    Automic