Home » Developer & Programmer » Forms » webutil_file_transfer.AS_to_Client always retrun false
webutil_file_transfer.AS_to_Client always retrun false [message #349786] Tue, 23 September 2008 02:21 Go to next message
S_Ashour
Messages: 13
Registered: September 2008
Junior Member
I have configured webutil package successfully

I have made the following configuration to webutil.cfg:
transfer.database.enabled=TRUE
transfer.appsrv.enabled=TRUE
transfer.appsrv.accessControl=TRUE
#List transfer.appsrv.read.<n> directories
transfer.appsrv.read.1=d:\temp
#List transfer.appsrv.write.<n> directories
transfer.appsrv.write.1=d:\temp

I have the following code:
BEGIN

IF NOT webutil_file_transfer.AS_to_Client('C:\temp\saad.pdf', 'd:\temp\saad.pdf') THEN
message('Upload was not successful');
ELSE
message('Upload was successful');
END IF;

END;

I always got "Upload was not successful" can any body tell me what the problem is ?
Re: webutil_file_transfer.AS_to_Client always retrun false [message #349796 is a reply to message #349786] Tue, 23 September 2008 02:43 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
Are you running AS or DS?

David
Re: webutil_file_transfer.AS_to_Client always retrun false [message #349826 is a reply to message #349796] Tue, 23 September 2008 04:17 Go to previous messageGo to next message
S_Ashour
Messages: 13
Registered: September 2008
Junior Member
I am running DS (oracle developer 10g R 10.1.2.0.2)..
Re: webutil_file_transfer.AS_to_Client always retrun false [message #349877 is a reply to message #349796] Tue, 23 September 2008 06:41 Go to previous messageGo to next message
S_Ashour
Messages: 13
Registered: September 2008
Junior Member
Can any one help me ?
Re: webutil_file_transfer.AS_to_Client always retrun false [message #350041 is a reply to message #349796] Tue, 23 September 2008 20:27 Go to previous messageGo to next message
S_Ashour
Messages: 13
Registered: September 2008
Junior Member
Hello David,

Can you please help me ?
Re: webutil_file_transfer.AS_to_Client always retrun false [message #350054 is a reply to message #350041] Tue, 23 September 2008 23:53 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
Hey! I have a day job and I try to have a life at night! Wait 24 hours before posting any 'are you there messages'!

As per the documentation, did you try "to call the WebUtil_File_Transfer_IsASReadable function with the target filename before starting the download to ensure that you will be able to read from this location on the application server"?

David
Re: webutil_file_transfer.AS_to_Client always retrun false [message #350085 is a reply to message #350054] Wed, 24 September 2008 01:28 Go to previous messageGo to next message
S_Ashour
Messages: 13
Registered: September 2008
Junior Member
My webutil.cfg is like this:

#NOTE: By default the file transfer is disabled as a security measure
transfer.database.enabled=TRUE
transfer.appsrv.enabled=TRUE
transfer.appsrv.workAreaRoot=
transfer.appsrv.accessControl=TRUE
#List transfer.appsrv.read.<n> directories
transfer.appsrv.read.1=d:\temp
#List transfer.appsrv.write.<n> directories
transfer.appsrv.write.1=d:\temp

My WHEN-BUTTON-PRESSED code is like this:

BEGIN
IF NOT webutil_file_transfer.Is_AS_readable('D:\temp\1.pdf') THEN
message('File is NOT readable..');
ELSE
message('File is readable..');
END IF;
END;

I always get the message "File is NOT readable..".
Re: webutil_file_transfer.AS_to_Client always retrun false [message #350101 is a reply to message #350085] Wed, 24 September 2008 02:31 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
Then change your code to include my suggestion and see what happens when you do so!!

David
Re: webutil_file_transfer.AS_to_Client always retrun false [message #350107 is a reply to message #350101] Wed, 24 September 2008 02:39 Go to previous messageGo to next message
S_Ashour
Messages: 13
Registered: September 2008
Junior Member
Sorry, What suggestion do you mean ?
Re: webutil_file_transfer.AS_to_Client always retrun false [message #350111 is a reply to message #350107] Wed, 24 September 2008 02:42 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
I posted: "call the WebUtil_File_Transfer_IsASReadable function with the target filename before starting the download to ensure that you will be able to read from this location on the application server". Its in the online reference manual.

David
Re: webutil_file_transfer.AS_to_Client always retrun false [message #350113 is a reply to message #350111] Wed, 24 September 2008 02:45 Go to previous messageGo to next message
S_Ashour
Messages: 13
Registered: September 2008
Junior Member
I did your suggestion before:

My WHEN-BUTTON-PRESSED code is like this:

BEGIN
IF NOT webutil_file_transfer.Is_AS_readable('D:\temp\1.pdf') THEN
message('File is NOT readable..');
ELSE
message('File is readable..');
END IF;
END;
Re: webutil_file_transfer.AS_to_Client always retrun false [message #350117 is a reply to message #350113] Wed, 24 September 2008 02:50 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
Sorry, missed your change. I expected you to have two tests - the old one and the new one.

Is "transfer.appsrv.read.1=d:\temp" correct??? Perhaps it should be "transfer.appsrv.read.1=c:\temp". That is , "c" versus "d".

David
Re: webutil_file_transfer.AS_to_Client always retrun false [message #350137 is a reply to message #350117] Wed, 24 September 2008 03:25 Go to previous messageGo to next message
S_Ashour
Messages: 13
Registered: September 2008
Junior Member
I have the following changes

transfer.appsrv.read.1=c:\temp

My WHEN-BUTTON-PRESSED code is like this:

BEGIN
IF NOT webutil_file_transfer.Is_AS_readable('c:\temp\1.pdf') THEN
message('File is NOT readable..');
ELSE
message('File is readable..');
END IF;
END;

The result is "File is NOT readable..".
Re: webutil_file_transfer.AS_to_Client always retrun false [message #350365 is a reply to message #350137] Wed, 24 September 2008 18:35 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
Of course it failed, the 'c' directory is NOT defined in the WRITE directory list!!! Reread my last post!!! Its the READ directory that should be 'c' in your 'webutil.cfg'.

David
Re: webutil_file_transfer.AS_to_Client always retrun false [message #611637 is a reply to message #349786] Sat, 05 April 2014 01:46 Go to previous messageGo to next message
nsr8060333
Messages: 3
Registered: April 2014
Location: Jordan
Junior Member

HI, IS THERE ANY ONE?
Re: webutil_file_transfer.AS_to_Client always retrun false [message #611640 is a reply to message #611637] Sat, 05 April 2014 03:01 Go to previous message
Littlefoot
Messages: 21805
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Sometimes, yes. Note that this is a forum, not chat line.
Previous Topic: Sundays with date
Next Topic: How to clear field on on-error trigger in oracle forms.
Goto Forum:
  


Current Time: Tue Mar 19 03:30:13 CDT 2024