cfexecute problem

hi, can anyone decipher what may be the problem with the error code below?  The problem is coming when trying to call a batch file, but the whole objective is to dynamically zip files while retaining their file structures.  If this is not the right approach, can you please give an example/suggestion of how best to do it?


: An exception occurred when invoking an external process.  
The cause of this exception was that: CreateProcess: 'c:\program files\winzip\wzzip' -rP 'D:\WebSites\IETM_DevSite\tempZips\' 'D:\WebSites\IETM_DevSite\data\EA-6B\ICAP III\Controls and Indicat\Aft Advisory Panel\*.*' error=2.  
The error occurred in D:\WebSites\IETM_DevSite\dnldComponents\getFile.cfm: line 22
20 :       <!--- <cfx_ZipMan action="add" zipfile="#zipFile#" input_files="#lstFiles#"> --->
21 :       <cfexecute name="'c:\program files\winzip\wzzip'"
22 :         arguments="-rP '#zipFile#' 'D:\WebSites\IETM_DevSite\data\EA-6B\ICAP III\Controls and Indicat\Aft Advisory Panel\*.*'" timeOut="10">
23 :       </cfexecute>
24 :       <cfexecute name="D:\WebSites\IETM_DevSite\dnldComponents\execWinZip.bat" ></cfexecute>


Please try the following:
Check the ColdFusion documentation to verify that you are using the correct syntax.
Search the Knowledge Base to find a solution to your problem.

Browser   Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.1.4322)
Remote Address
Date/Time   01-Dec-03 03:37 PM
Stack Trace (click to expand)  
at cfgetFile2ecfm2018900984.runPage(D:\WebSites\IETM_DevSite\dnldComponents\getFile.cfm:22) at cfgetFile2ecfm2018900984.runPage(D:\WebSites\IETM_DevSite\dnldComponents\getFile.cfm:22) CreateProcess: &apos;c:\program files\winzip\wzzip&apos; -rP &apos;D:\WebSites\IETM_DevSite\tempZips\; &apos;D:\WebSites\IETM_DevSite\data\EA-6B\ICAP III\Controls and Indicat\Aft Advisory Panel\*.*&apos; error=2
      at java.lang.Win32Process.create(Native Method)
      at java.lang.Win32Process.<init>(
      at java.lang.Runtime.execInternal(Native Method)
      at java.lang.Runtime.exec(
      at java.lang.Runtime.exec(
      at java.lang.Runtime.exec(
      at java.lang.Runtime.exec(
      at coldfusion.tagext.lang.ExecuteTag.doStartTag(
      at cfgetFile2ecfm2018900984.runPage(D:\WebSites\IETM_DevSite\dnldComponents\getFile.cfm:22)
      at coldfusion.runtime.CfJspPage.invoke(
      at coldfusion.tagext.lang.IncludeTag.doStartTag(
      at coldfusion.filter.CfincludeFilter.invoke(
      at coldfusion.filter.ApplicationFilter.invoke(
      at coldfusion.filter.PathFilter.invoke(
      at coldfusion.filter.ExceptionFilter.invoke(
      at coldfusion.filter.BrowserDebugFilter.invoke(
      at coldfusion.filter.ClientScopePersistenceFilter.invoke(
      at coldfusion.filter.BrowserFilter.invoke(
      at coldfusion.filter.GlobalsFilter.invoke(
      at coldfusion.filter.DatasourceFilter.invoke(
      at coldfusion.CfmServlet.service(
      at jrun.servlet.ServletInvoker.invoke(
      at jrun.servlet.JRunInvokerChain.invokeNext(
      at jrun.servlet.JRunRequestDispatcher.invoke(
      at jrun.servlet.ServletEngineService.dispatch(
      at jrun.servlet.jrpp.JRunProxyService.invokeRunnable(
      at jrunx.scheduler.ThreadPool$DownstreamMetrics.invokeRunnable(
      at jrunx.scheduler.ThreadPool$ThreadThrottle.invokeRunnable(
      at jrunx.scheduler.ThreadPool$UpstreamMetrics.invokeRunnable(

Who is Participating?
Hi there,

Does your attribute NAME start (and end) width an " and a ' ???? if so remove the ' at the begin and end like this:

<cfexecute name="c:\program files\winzip\wzzip" arguments="-rP '#zipFile#' 'D:\WebSites\IETM_DevSite\data\EA-6B\ICAP III\Controls and Indicat\Aft Advisory Panel\*.*'" timeOut="10">

liltygaAuthor Commented:
Thanks for the post references Anand - since they pointed me in the right direction, I'm accepting your comments as the answer.  The solution I found was to use the ZipFileNew UDF, which is free and can be found here:  (Thanks to Nathan Dintenfass for the code contribution!)

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.