Link to home
Start Free TrialLog in
Avatar of chalie001
chalie001

asked on

delete file in server after upload

hi how to delete file in oracle webutil after download

i try this

PROCEDURE openreportoutput (pfilename varchar2) IS
	V_KDIC_PATH  varchar2(255) :='C:\;
	v_clientfile varchar2(255);
	vfilename varchar2(255);
	vs boolean;
	v_output  VARCHAR2(4000);
	
BEGIN
message('newfrm');

  tool_env.getvar('OUTPUT', v__output);
  vfilename := substr(pfilename, instr(pfilename,'/',-1)+1);
 
  v_clientfile :=webutil_clientinfo.get_system_property('user.home')||'\'||vfilename;

  
   vs := webutil_file_transfer.as_to_client_with_progress(v_clientfile,pfilename,'Downloading ...','OK');
   if vs then
   	   client_host ('explorer '||v_clientfile);
   	   message('Opening report in excel ....');
   	   message(' ');
   else
   	   message('File transfer Error !!!!');
   	   message(' ');
   end if;
   message('del12 ');
   host ('del '||v_ncs_output||'/'||vfilename);
   message('del2 ');
   
end;  

Open in new window

Avatar of slightwv (䄆 Netminder)
slightwv (䄆 Netminder)

I'm not a web_util person but there appears to be a webutil_file.delete_file
Avatar of chalie001

ASKER

How do I use it in my code
Am getting file is not a procedure
As I mentioned above, I'm not a forms/webutil person.  I cannot tell you how to write the code.

If the file is on the client side that you want to delete, take a look at:
https://community.oracle.com/thread/1062776
This question needs an answer!
Become an EE member today
7 DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform.
View membership options
or
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.