#1
  1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jun 2003
    Posts
    4
    Rep Power
    0

    Post How can I run a coldfusion executable through an NT batch program?


    I generate some excel reports (basically are excel outputs of regular HTML reports) using the ColdFusion scheduler. How do I continue generating the same reports using the ColdFusion files but using the NT batch program instead of the ColdFusion scheduler?
  2. #2
  3. No Profile Picture
    Moderator

    Join Date
    Jun 2002
    Location
    Raleigh, NC
    Posts
    5,278
    Rep Power
    968
    Not sure about the answer, but it might help to know that the CFSCHEDULE engine is, basically, an interface into the NT scheduled task engine, or the UNIX chron job engine. So as far as I know you can schedule whatever you need to run directly in the NT scheduled tasks. Now, how to tell it that you want to execute a URL as the task is another story...;-)
  4. #3
  5. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Nov 2003
    Posts
    3
    Rep Power
    0
    you can use the windows scripting host.

    Create a file with a .vbs extension with the following inside of it:


    'Create an instance of IE
    Dim IE
    Set IE = CreateObject("InternetExplorer.Application")

    'Execute your URL
    ie.navigate("http://urltoyourcfpage.cfm")

    'Clean up...
    Set IE = Nothing


    Change http://urltoyourcfpage.cfm to the url to your cfm file. Then have the scheduled task execute that vbs file.

IMN logo majestic logo threadwatch logo seochat tools logo