Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
IWFileUploader locking file
#1
I'm on IW15.1.10 and I'm using a TIWFileUploader to upload a file.
Everything is ok but when I try to access the original file, the one to be uploaded, by another external app, it woin't be possible because the file is locked, is in use. So it seems that IWFileUploader is locking the file.
Is something that I'm missing? How can I workaround this?

Thanks
Reply
#2
The file uploader doesnt "save" the file except in a temp area. Your code is the one that saves/copies it to where you want. Its is either your code forgetting to free a stream/close a file, or possibly your antivirus scanning the file as it sees it is new.
Reply
#3
Yes, I know that. I’m doing the exactly the you mentioned on your demo of the IWFileUploader. 
Maybe your second thought, the antivirus. 
I’d saving to a memory stream and the same happens. Could it be antivirus also?
Reply
#4
(01-07-2020, 02:57 PM)kudzu Wrote: The file uploader doesnt "save" the file except in a temp area. Your code is the one that saves/copies it to where you want. Its is either your code forgetting to free a stream/close a file, or possibly your antivirus scanning the file as it sees it is new.
Well, that I know and I'm doing the file upload exactly how your demo explains. I even try saving to a stream and even so the file will be in use. Yes, I'm freeing the stream.

So, the is either on the TIWFileUploader itself or, as you stated, on the antivirus.
Reply
#5
Since TIWFileUploader only keeps the internal temp file, it can't be it.

Try just as a test temporarily disabling your AV. If that fixes it, then there are a variety of solutions but the first step is to find what has it locked. You can also use a tool like filemon.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)