SetHeader problem when user downloads a file from a server
Hi everyone,
I have a question about the way to let a user download a file. A created a jsp that handles the download. This is the code:
<%@ page import="java.io.*" %><%
response.setHeader("Content-Disposition", "attachment; filename=" + session.getAttribute("executedCommand").toString());
response.setContentType("text/csv");
int iRead;
FileInputStream stream = null;
try {
File f = new File(session.getAttribute("executedCommand").toString());
stream = new FileInputStream(f);
while ((iRead = stream.read()) != -1) {
out.write(iRead);
out.flush();
}finally {
if (stream != null) {
stream.close();
%>When I run this, I get a download window, so that the right file can be downloaded, but I would like the application to show me the name of that file in the download window and in my save dialog, and that's something I haven't managed to do yet, because I always get the name of the servlet (that redirects to the jsp page). So the problem is, the right file is downloaded but it's name is never shown in the download window. How can I resolve that?
Thanks for your help!
E_J
I forgot to say that my session variable contains the absolute path of the file the user can download. Maybe using session variables is not the best solution in this case, but it should have to work, shouldn't it?
Still waiting for some help. I really appreciate it...
E_J
Similar Messages
-
Download text file from application server to client server.
Hi all,
I am facing a format issue while downloading text file from application server to the client machine.
The issue is that, say I have 6 to 10 lines in my text file in application server. but when i store it on the hard drive,
it shoes all the data in a single line. Where as i need to download data in same format as in application server.
Awaiting for your responses.
Regards,
JoseHi,
If we want to upload file data from the application server to the internal table, there is no function module or class static method which we can use, we must wirte the code by ourselves.
1. For the file data which has no seperator between field columns.
PARAMETERS p_file TYPE dxfile-filename.
START-OF-SELECTION.
OPEN DATASET p_file IN TEXT MODE ENCODING DEFAULT FOR INPUT.
DO.
READ DATASET p_file INTO gds_data.
IF sy-subrc <> 0.
EXIT.
ENDIF.
APPEND gds_data TO gdt_data.
ENDDO.
CLOSE DATASET p_file.2. For the file data which has tab separator between field columns.
DATA: gds_field_split type gts_data.
FIELD-SYMBOLS: <fs_field> TYPE gts_data.
PARAMETERS p_file TYPE dxfile-filename.
START-OF-SELECTION.
OPEN DATASET prf_file IN TEXT MODE ENCODING DEFAULT FOR INPUT.
DO.
READ DATASET p_file INTO gds_field.
SPLIT gds_field AT cl_abap_char_utilities=>horizontal_tab
INTO TABLE gdt_field_split.
LOOP AT gdt_field_split into gds_field_split.
gdf_index = gdf_index + 1.
ASSIGN COMPONENT gdf_index OF STRUCTURE
gds_data to <fs_field>.
IF sy-subrc = 0.
<fs_field> = gds_field_split.
ENDIF.
ENDLOOP.
APPEND gds_data TO gdt_data.
ENDDO.
CLOSE DATASET p_file.
Thanks & regards,
ShreeMohan -
How to download a file from application server to presentation server
Hi experts,
I want to download a file from application server to presentaion server, file contaims three fields customer name, customer email id and status..
help me out i m new into sap.Dear Aditya,
Please check below thread
http://scn.sap.com/thread/1010164
it will help you.
BR
Atul -
Downloading a file from App Server to User's Desktop
Hi All,
I know that there are many threads on file upload and download :-)
I have tried to browse through most of them and could not find my solution.
The requirement is to place a file in the unix app server directory and allow the user to download it using a link, to the user's desktop. In case you think that this has already been answered in an old thread, kindly give me the pointer. Any sample code for doing this, would be great.
I know how to upload a file from desktop to table/app server. I know how to download a file from a BLOB column in database.
Thanks,
AmitYou would not be able to use file upload or download beans, as they interact with the database and not the filesystem.
You would need to write a simple file reader routing in plain java.
Tapash -
every time i download a file from the web (ie. a PDF file) i get "Anti-Virus Program not found " message. This has been happening since I changed anti-virus programs for CA etrust to Sophos. How do I get Firefox to recognise my new Anti-virus program?
That is a very good warning provided by the Download Statusbar extension. Something like that should been built into Firefox. I filed this Bug report a couple of years ago, about the lack of a warning like that. <br />
https://bugzilla.mozilla.org/show_bug.cgi?id=480855 <br />
I have looked everywhere that I can think of to find a list of '''IOfficeAntiVirus providers''' ''(as mentioned in the Bug report)'' that will work with Firefox, so I can't answer that for you.
You might want to ask the developer of the Download Statusbar extension about it. He might know which AV programs are compatible with the Windows API that Firefox uses for the download scan. <br />
http://dlstatusbar.proboards.com/index.cgi? <br /> -
User's work-files are hosted on a Windows Server 2003 SP2 volume accessed via SMB. She's been opening and saving the files from the server successfully in Dreamweaver for years from other Macs running Dreamweaver CS4.
Now she has an iMac running 10.7.4 and Dreamweaver CS6... and it's not the SMB problem you'd expect.
She mounts the server volume. She opens and saves files normally with full r/w permissions from any app... except Dreamweaver. For any file that she attempts to open in Dreamweaver -- whether from the Finder or from within Dreamweaver -- Dreamweaver pops up an alert reporting that the file at the file-path was not found. The same file is easily accessible from other apps and from the Finder. She continues to have full read/write access to the shared volume.
Local copies of the files do not have the problem. It only affects files hosted on the server and it only happens in Dreamweaver.
So, I create a new user account and everything works fine... The user mounts the sharepoint, opens a file with Dreamweaver... perfectly normal. Then she quits Dreamweaver and relaunches it... everything's fine. Repeatedly. It all works normally. She quits Dreamweaver and unmounts the share, then she mounts the share again and tries to open a file in Dreamweaver again... and it reports that the file was not found.
This is reproducible: If the server volume has been mounted and unmounted repeatedly under any user account, that triggers the error which continues occurring under that user account from that point on. A restart will not fix it. A safe-boot will not fix it. (In fact, restarting seems to trigger the problem by unmounting the volume.)
I tried trashing the entire contents of the ~/Library folder in one of the test-user accounts. It doesn't fix the problem. Once it strikes a user account, the only temporary fix seems to be using a new user account. And that's like a ticking time bomb just waiting for the problem to pop up again.
Any ideas?
TIA!!I've seen on two computers so far. Looking at the mount point under unix, the share is being mounted at two different locations. This is normal behaviour for Macs when you mount two different shares with the same name.
From terminal I run:
df
Which returns something like
/dev/disk0s2 1951845952 224463456 1726870496 12% /
devfs 360 360 0 100% /dev
map -hosts 0 0 0 100% /net
map auto_home 0 0 0 100% /home
//[email protected]/website 204360384 38067872 166292512 19% /Volumes/website
//[email protected]/website 204360384 38067872 166292512 19% /Volumes/website-1
map -fstab 0 0 0 100% /Network/Servers
Notice that the share "website" has been mounted once as website, and again as website-1. This is the underlying unix name for the share, which is how most programs (99% sure including Adobe suite products) will reference files. So, if it thinks that the file is at /Volumes/website/site/index.html but can only see /Volumes/website-1/ then it doesn't know what to do.
The confusion arises because both will show in Finder as "website". Even more annoying is that Finder does not always unmount shares correctly, so that /Volumes/website might not be accessible but /Volumes/website-1 will be. As far as the user is concerned, the share "website" is still mounted, but as far as Dreamweaver is concerned, it isn't, although website-1 is.
It's the same share, same data, but is being referenced by different names, so does not seem accessible.
BUT
I don't have a solution yet, apart from force unmounting both (or rebooting), remounting, and checking that Dreamweaver is using the right share (perhaps by removing and readding from within Dreamweaver).
Tedious. -
How to download a file from Middleware server
Hi,
I have a requirement to list file names in a table layout and when user clicks on file name, file must be downloaded to the client tier. Source files are located in 11i Apps middletier.
I did not find any examples on how to achieve this using OAF. All I see is downloading file from BLOB inside a database.
please help..OAMessageDownloadBean is the bean that lets you download a file from middletier.
Please see the File Upload and Download chapter in devguide for implementation details.
Thanks
Tapash -
Download PDF file from Application Server in BSP
Hello,
We have a requirement on which we want to download a PDF file stored in Application server using BSP application. I have used function module ARCHIVFILE_SERVER_TO_CLIENT but this FM will help only if i want to download file from GUI it won't work in BSP application.
Further i have used class CL_BSP_UTILITY and download method to download file from application server but it is not working in desired manner.
I am attaching my code for your reference:
DATA: BUTTON_EVENT TYPE REF TO CL_HTMLB_EVENT_BUTTON ,
EVENT TYPE REF TO IF_HTMLB_DATA.
DATA: LS_HOURS LIKE LINE OF GT_HOURS.
DATA STR TYPE STRING.
DATA: OUTPUT TYPE STRING ,
L_XSTRING TYPE XSTRING ,
APP_TYPE TYPE STRING.
EVENT = CL_HTMLB_MANAGER=>GET_EVENT( REQUEST ).
DATA PHY_NAME_OUT TYPE SAPB-SAPPFAD.
IF EVENT IS NOT INITIAL AND EVENT->EVENT_NAME = HTMLB_EVENTS=>BUTTON .
BUTTON_EVENT ?= EVENT .
CASE EVENT->EVENT_SERVER_NAME.
WHEN 'test' .
IF GT_HOURS IS NOT INITIAL.
PHY_NAME_OUT = '/usr/sap/put/form16//01000200_2007.PDF'.
OPEN DATASET PHY_NAME_OUT FOR INPUT IN TEXT MODE ENCODING DEFAULT.
IF SY-SUBRC IS INITIAL.
DO.
READ DATASET PHY_NAME_OUT INTO STR.
IF SY-SUBRC IS INITIAL.
CONCATENATE
OUTPUT
str
cl_abap_char_utilities=>cr_lf
INTO output SEPARATED BY space. "cl_abap_char_utilities=>horizontal_tab
ELSE.
EXIT.
ENDIF.
ENDDO.
ENDIF.
*LOOP AT gt_hours INTO ls_hours.
*CONCATENATE
*OUTPUT
*ls_hours-hour
*cl_abap_char_utilities=>cr_lf
*INTO output SEPARATED BY space. "cl_abap_char_utilities=>horizontal_tab
*ENDLOOP.
APP_TYPE = 'APPLICATION/PDF;charset=utf-16le'.
CALL FUNCTION 'SCMS_STRING_TO_XSTRING'
EXPORTING
TEXT = OUTPUT
MIMETYPE = 'APPLICATION/PDF;charset=utf-16le'
IMPORTING
BUFFER = L_XSTRING.
CONCATENATE CL_ABAP_CHAR_UTILITIES=>BYTE_ORDER_MARK_LITTLE
L_XSTRING
INTO L_XSTRING IN BYTE MODE.
CALL METHOD CL_BSP_UTILITY=>DOWNLOAD
EXPORTING
OBJECT_S = L_XSTRING
CONTENT_TYPE = APP_TYPE
CONTENT_DISPOSITION = 'attachment;filename=webforms.pdf'
RESPONSE = _M_RESPONSE
NAVIGATION = NAVIGATION.
ENDIF.
ENDCASE.
ENDIF.
From this code i am able to download PDF file but it is not opening in local machine.
If any other way to download file then please suggest.
waiting for ur reply.
Regards,
GaganHi,
you do the file reading wrong:
have a look at:
Local declarations.
data:
components type stringtab,
component type string,
path type text255,
file type text255,
line_length type i,
filecontent_binary type sdokcntbin,
rows type sytabix,
content type sdokcntbin,
exception type ref to cx_sy_file_access_error,
exception_tmf type ref to cx_sy_too_many_files ,
block_size type i value 1022,
length type i.
field-symbols:
<hex_container> type x.
constants:
c_dms_blk_size type i value 2550.
clear file_size.
try.
open dataset file_name for input in binary mode message message.
catch cx_sy_file_open into exception.
case exception->textid.
when '4182174D03030063000000000A1551B1'. raise access_error.
when '41825AD355C3005E000000000A1551B1'. raise open_error.
when '47E8B03AECE5BA07E10000000A114829'. raise already_open.
when others.
endcase.
catch cx_sy_file_authority into exception.
case exception->textid.
when '4182174D03030063000000000A1551B1'. raise access_error.
when 'A70BB8396F051547E10000000A11447B'. raise authority_error.
when others.
endcase.
catch cx_sy_too_many_files into exception_tmf.
case exception_tmf->textid.
when '8708B73915F6B645E10000000A11447B'. raise too_many_files.
when others.
endcase.
endtry.
do.
try.
read dataset file_name into filecontent_binary-line.
if sy-subrc <> 0.
add line_length to file_size.
append filecontent_binary to file_content_binary.
exit.
else.
add line_length to file_size.
append filecontent_binary to file_content_binary.
endif.
catch cx_sy_file_open_mode into exception.
case exception->textid.
when '9207B73915F6B645E10000000A11447B'. raise cx_sy_file_open_mode.
when '9807B73915F6B645E10000000A11447B'. raise read_only.
when '9E07B73915F6B645E10000000A11447B'. raise not_open.
when '409D273A2D824360E10000000A11447B'. raise incompatible_mode.
when others.
endcase.
endtry.
enddo.
try.
close dataset file_name.
catch cx_sy_file_close into exception.
case exception->textid.
when '4182174D03030063000000000A1551B1'. raise access_error.
when 'C10BB8396F051547E10000000A11447B'. raise close_error.
when others.
endcase.
catch cx_sy_file_access_error into exception.
case exception->textid.
when '4182174D03030063000000000A1551B1'. raise access_error.
when others.
endcase.
endtry.
Get file size.
split file_name at '/' into table components.
describe table components lines sy-tfill.
read table components into component index sy-tfill.
path = file_name.
replace component in path with ''.
file = component.
call function '/EUH/MMS_GET_FILE_SIZE'
exporting
dir_name = path
file_name = file
importing
file_size = file_size.
and function /euh/mms_get_file_size.
""Local Interface:
*" IMPORTING
*" VALUE(DIR_NAME) TYPE TEXT255
*" VALUE(FILE_NAME) TYPE TEXT255
*" EXPORTING
*" VALUE(FILE_SIZE) TYPE SDOK_FSIZE
*" EXCEPTIONS
*" NO_AUTHORITY
*" ACTIVITY_UNKNOWN
*" NOT_A_DIRECTORY
*" NO_MEDIA_IN_DRIVE
*" TOO_MANY_ERRORS
*" TOO_MANY_FILES
*" BRACKET_ERROR_IN_FILENAME
*" NO_SUCH_PARAMETER
types: begin of files,
line like ocs_file,
end of files.
data: file type files,
f_subrc like sy-subrc value 0,
errno(3) type c,
errmsg(40) type c,
pos type i,
len type i,
parameter(120) type c,
help1(120) type c,
help2(120) type c,
error_counter type i.
data:
dir_list like ocs_file occurs 0 with header line.
CASE sy-subrc.
WHEN 1. f_subrc = 64.
WHEN 2. f_subrc = 65.
WHEN 0.
search dir_name for 'SY-HOST'. "Is SY-HOST used in directory name?
if sy-subrc = 0.
pos = sy-fdpos + 7.
move dir_name(sy-fdpos) to help1.
move dir_name+pos to help2.
concatenate help1 sy-host help2 into dir_name.
endif.
do 12 times. " To avoid endless loop
if dir_name cs '$('. " Replace parameter by their value
pos = sy-fdpos + 2.
if dir_name cs ')'.
len = sy-fdpos - pos.
if len le 0.
f_subrc = 4. exit.
else.
parameter = dir_name+pos(len).
call 'C_SAPGPARAM' id 'NAME' field parameter
id 'VALUE' field parameter.
if sy-subrc = 0.
len = pos + len + 1.
pos = pos - 2.
if pos > 0.
move dir_name(pos) to help1.
else.
help1 = ''.
endif.
pos = strlen( dir_name ).
if pos > len.
move dir_name+len to help2.
else.
help2 = ''.
endif.
concatenate help1 parameter help2 into dir_name.
else.
f_subrc = 8. exit.
endif.
endif.
else.
exit.
endif.
else.
exit.
endif.
enddo.
shift dir_name right deleting trailing '/\ '.
shift dir_name left deleting leading space.
call 'C_DIR_READ_FINISH' " this is from RSWATCH0
id 'ERRNO' field errno
id 'ERRMSG' field errmsg.
call 'C_DIR_READ_START'
id 'DIR' field dir_name
id 'FILE' field file_name
id 'ERRNO' field errno
id 'ERRMSG' field errmsg.
case sy-subrc.
when 1.
case errno.
when 2 or 20. f_subrc = f_subrc + 66.
when ' '. f_subrc = f_subrc + 67.
endcase.
when 0.
clear error_counter.
do.
clear file.
clear dir_list.
call 'C_DIR_READ_NEXT'
id 'TYPE' field file-line-type
id 'NAME' field file-line-name
id 'LEN' field file-line-len
id 'OWNER' field file-line-owner
id 'MTIME' field file-line-mtime
id 'MODE' field file-line-acc_mode
id 'ERRNO' field errno
id 'ERRMSG' field errmsg. "sy-subrc = 3 is e.g. if return
if sy-subrc = 0 or sy-subrc = 3."data do not fit into variables
perform p6_to_date_time_tz(rstr0400) using
file-line-mtime
file-line-mod_time
file-line-mod_date.
file_size = file-line-len.
dir_list = file-line.
append dir_list.
elseif sy-subrc = 1. " nothing (more) found
exit.
else.
if error_counter > 50.
call 'C_DIR_READ_FINISH'
id 'ERRNO' field errno
id 'ERRMSG' field errmsg.
pos = f_subrc mod 2.
if pos = 0. f_subrc = f_subrc + 1. endif.
exit.
endif.
add 1 to error_counter.
endif.
if sy-index > 1000.
pos = f_subrc mod 4.
if pos = 0. f_subrc = f_subrc + 2. endif.
exit.
endif.
enddo.
call 'C_DIR_READ_FINISH'
id 'ERRNO' field errno
id 'ERRMSG' field errmsg.
if sy-opsys(3) = 'Win' and not ( file_name cs '*' ).
describe table dir_list lines len.
if len = 0.
help1 = file_name.
translate help1 to upper case.
translate help1 using
'ABCDEFGHIJKLMNOPQRSTUVWXYZ'.
call 'C_DIR_READ_START'
id 'DIR' field dir_name
id 'FILE' field help1.
if sy-subrc = 0.
clear error_counter.
do.
clear file.
clear dir_list.
call 'C_DIR_READ_NEXT'
id 'TYPE' field file-line-type
id 'NAME' field file-line-name
id 'LEN' field file-line-len
id 'OWNER' field file-line-owner
id 'MTIME' field file-line-mtime
id 'MODE' field file-line-acc_mode
id 'ERRNO' field errno
id 'ERRMSG' field errmsg.
if sy-subrc = 0 or sy-subrc = 3.
help2 = file_name.
translate help2 to upper case.
help1 = file-line-name.
translate help1 to upper case.
if help1 = help2.
perform p6_to_date_time_tz(rstr0400) using
file-line-mtime
file-line-mod_time
file-line-mod_date.
dir_list = file-line.
append dir_list.
endif.
elseif sy-subrc = 1.
exit.
else.
if error_counter > 50.
call 'C_DIR_READ_FINISH'
id 'ERRNO' field errno
id 'ERRMSG' field errmsg.
pos = f_subrc mod 2.
if pos = 0. f_subrc = f_subrc + 1. endif.
exit.
endif.
add 1 to error_counter.
endif.
if sy-index > 1000.
pos = f_subrc mod 4.
if pos = 0. f_subrc = f_subrc + 2. endif.
exit.
endif.
enddo.
call 'C_DIR_READ_FINISH'
id 'ERRNO' field errno
id 'ERRMSG' field errmsg.
endif.
endif.
endif.
endcase.
ENDCASE.
CASE f_subrc.
WHEN 1 OR 3. RAISE too_many_errors.
WHEN 2. RAISE too_many_files.
WHEN 4 OR 5 OR 6 OR 7 OR 70 OR 71.
RAISE bracket_error_in_filename.
WHEN 8 OR 9 OR 10 OR 11 OR 74 OR 75.
RAISE no_such_parameter.
WHEN 64. RAISE no_authority.
WHEN 65. RAISE activity_unknown.
WHEN 66. RAISE not_a_directory.
WHEN 67. RAISE no_media_in_drive.
ENDCASE.
endfunction.
Now you will be able to get the filesize and the file in SDOK format sdokbin.
Okay.
You have to build an request and push the content to the user like:
call method server->response->set_header_field( name = 'Content-Type' value = value ).
describe field file_content_binary-line length line_length in byte mode.
bytes_rest = file-size.
loop at file_content_binaries assigning <file_content_binary>.
move <file_content_binary>-line to data.
if bytes_rest <= 0. "mismatch between line values and size
exit.
endif.
if bytes_rest >= line_length.
call method server->response->append_data( data = data
length = line_length ).
else.
call method server->response->append_data( data = data
length = bytes_rest ).
endif.
bytes_rest = bytes_rest - line_length.
endloop.
This will work.
You can set the header fields like you want. Have also a look at sicf node contentserver
and its handler: CL_HTTP_EXT_CSIF -
Error while downloading PDF file from FTP Server
Hi Friends,
I have sent a PDF file with data to FTP , Then i want to check that uploaded pdf file , whether that is correct or not?
for that , i have downloaded that file from FTP and i am trying to open the file . but it is giving this problem .
"There was an error opening the document . The file is damaged and could not be repaired."
will you suggest me regarding this.
thanks in advance.
balaji.T.CALL FUNCTION 'CONVERT_OTFSPOOLJOB_2_PDF'
EXPORTING
SRC_SPOOLID = spoolno
src_spoolid = wa_file-rqident
no_dialog = ' '
DST_DEVICE =
PDF_DESTINATION =
IMPORTING
pdf_bytecount = numbytes
pdf_spoolid = pdfspoolid
OTF_PAGECOUNT =
btc_jobname = jobname
btc_jobcount = jobcount
TABLES
pdf = pdf
EXCEPTIONS
err_no_otf_spooljob = 1
err_no_spooljob = 2
err_no_permission = 3
err_conv_not_possible = 4
err_bad_dstdevice = 5
user_cancelled = 6
err_spoolerror = 7
err_temseerror = 8
err_btcjob_open_failed = 9
err_btcjob_submit_failed = 10
err_btcjob_close_failed = 11.
because of this one PDF internal table is obtained.
OPEN DATASET L_FILENAME FOR OUTPUT in text mode MESSAGE MSG.
LOOP AT pdf.
CONCATENATE pdf-tdformat "Material group
pdf-TDLINE "Basic Material
INTO ITEXT-TLINE ..
APPEND ITEXT.
TRANSFER ITEXT TO L_FILENAME.
ENDLOOP. -
How to Download a file from web server using servlets
how do we download a file from Java Web Server connecting to oracle database
it should start as soon a i click a button in my html browser
please reply as it is needed to complete my project to submited to the collageWith SQLJ you can do it.
When you look at:
http://otn.oracle.com/sample_code/tech/java/sqlj_jdbc/files/basic/basic.htm
or
http://otn.oracle.com/sample_code/tech/java/sqlj_jdbc/files/advanced/advanced.htm
There are samples for reading LONGRAW / BLOB from Database. If you want use it in servlet you have to pass the result to the responce object, set the correct mime-type and set the response.setContentLength( xx). This is for some PlugIns nessessary (pdf).
regards Dietmar -
Error when loading a flat file from Application server.
Hi,
I am trying to load a flatfile from the application server, and I am getting the message
Error while accessing the application server file
Message no. RSDS_ACCESS002
I checked for notes and found only one:
Note 1033978 - Correction: Loading Unicode files from application server
but we have 19 SP level, and the note says it needs 13 SP level, so I think it would not be of any help.
does anybodie know what to do??
thanks for the help.
MauricioError in accessing while application server file..
when i am trying load the data to psa
when i am taking the file name: text-type file from app server
plz reslove me for this problem??
another question
when i am saving the file with using * in the filename in .CSV file its not saving,
whats the reason????
ASHOK -
Download PDF file from APP server!
Hi!
Has anyone tried uplaoding and downloding a PDF table from app server as I tried from a normal method by Open dataset, Transfer but it wont work.
Please provide any inputs.
Thanks.Hi park,
1. Using open data set, transfer , close etc,
also it will work.
( it will download / upload any kind of file from app server)
2. Just make sure the
FULL PATHNAME and the FILENAME
are mentioned in EXACT CASE
(small/CAPITAL).
3. U can check thru transaction AL11, to see the file and path.
regards,
amit m. -
Download ECS files from the server
Currently we have production on Oracle Application Server Integration B2B, Release 10.1.2, Build B2B_10.1.2.4.0_GENERIC_100714.
Is there a way to download current ECS files from the prod server?
Regards,
Suneel JakkaDownload ECS files from the server
Regards,
Anuj -
When I download .pdf files from my office they are converted to .ashx files
When I download a .pdf file from my Outlook mail box at my office, Firefox reads it as an .ashx file. However if I use Safari, it is read correctly as a .pdf file.
How can I fix my Firefox browser?
An IT person at my office said I should reset the download actions by deleting mime.Types.rdf, but I can't even find this file.See [[/en-US/questions/894442]]
-
How to download a file from a server
Hi,
I have a question with a general design implementation. Hope anyone more skilled than me helps me.
I want to do an application based on an android client and a java server. Local wifi transmission, no 3G.
Basically, the client must connect to the server and request a file to download using a code.
How can I do that?
Things I know:
* I must create a background thread in the client to create a file in the SD card and update a progress bar using a Handler to communicate with the UI thread.
* The server must be multithread and non-blocking.
* The file is a binary file like a mp3 audio. So the server has to:
1. Send information about the file: name and total length.
2. Open the file, read and send bytes while it does not reach the end.
* The client has to:
1. Receive the information about the file and create an empty file.
2. Read bytes and dump them into the empty file. Update progress bar.
3. When all bytes are recieved close the file.
I have knowledge implementing a client and server in C (very awful) but I am beginning with a real client-server application done in java.
Questions:
* How can I download a binary file like an mp3 from a server to a client?
* Where I have to put my server application? I supose that I must create a jar, save it on a folder and execute it at PC start-up, right?
Thanks!
PD: I know this is not an android forum but I only need help with the download process.
Edited by: user13425637 on 06-dic-2010 11:08Questions:
* How can I download a binary file like an mp3 from a server to a client?There are a ton of examples on the internet on how to download files. If you are having a problem, please post your code.
>
* Where I have to put my server application? I supose that I must create a jar, save it on a folder and execute it at PC start-up, right?Your server application will exist on a server and will run the application. hence the reason for the server. The best best for you is to read some online tutorials on client/server and how it works.
Maybe you are looking for
-
When I click on a photo I see a yield sign with an exclamation point in it.
When I'm in an event I can see all my photos for that event, but when I open one of the photos I get an exclamation point in a yield sign shaped ICON. Is the photo damaged ? How do I repair this condition and how do I avoid it next time. Not all m
-
I recieved a $100 Mac App Store gift card with the Back to School promo, and I was wondering if I could use it on the Apple Store website to buy another product.
-
Hi all, I'm having problems with reconstruct. In many mailboxes, when I execute it, the command does not make anything. For example: sh-3.2# /usr/bin/cyrus/bin/reconstruct -r -f user/userdomaines but with other mailboxes, the reconstruct works fine.
-
**bleep** Poor Customer Service
I was with Verizon for 12 months and would have continued service for at least another year if my current location had Verizon access; however, after trying to deal with a finance issue that involved Verizon creating some sort of phantom account that
-
Cannot enable photo stream or set options
Attempting to enable photo stream under my wife's Windows 7 account. I go to the iCloud control panel applet and tick photo stream. I then attempt to adjust the location of the stream folder by clicking the options button. Nothing happens. I do n