Ok Kris, you are right.
my controller now is:
        <cffunction name="cancellaImg"
                                access="public"
                                output="false"
                                returntype="ModelGlue.Core.Event">
                <cfargument name="event" type="ModelGlue.Core.Event"
required="true" />
                        <cfset var modello = 
arguments.event.getValue("modello")>
                        <cfset var img = arguments.event.getValue("img")>
                        <cfset var img2delete = beans.settingMgr.getCataloghi() 
& modello &
"/" & img>
                        <cfset var deletedImgs = 
beans.settingMgr.getCataloghi() &
"deleted" >
                        <cftry>
                           <cffile action="delete" 
file="#expandPath(img2delete)#">
                           <cfcatch type="any">
                             <cfthrow message="#cfcatch.type#">
                           </cfcatch>
                        </cftry>
                        <cfset arguments.event.setValue("slide",modello)>
                        <cfreturn arguments.event />
        </cffunction>

i added a cftry/cfcatch block to see error type, that is application.
thank you
salvatore


On 16 Set, 11:02, Chris Blackwell <[email protected]> wrote:
> salvatore,
> The amount of help we can provide is directly related to the amount of
> information and code samples you can give us to look at.  Please post your
> upload controller method so we can see what you are doing.
>
> From what you describe it seems like you are some who leaving a file handle
> open on the uploaded image, but without seeing your code i really can't
> offer a solution.
>
> Chris
>
> 2009/9/16 salvatore fusto <[email protected]>
>
>
>
>
>
> > hi,
> > i've a simple method of a controller to upload a jpg: doing this
> > however i've noted that my jpg remains locked after upload, i.e. i
> > cannot delete it, until i reload the framework.
> > can i solve?
> > regards
> > salvatore- Nascondi testo citato
>
> - Mostra testo citato -
--~--~---------~--~----~------------~-------~--~----~
Model-Glue Sites:
Home Page: http://www.model-glue.com
Documentation: http://docs.model-glue.com
Bug Tracker: http://bugs.model-glue.com
Blog: http://www.model-glue.com/blog

You received this message because you are subscribed to the Google
Groups "model-glue" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/model-glue?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to