Send Blob Contents to Client machine as Attachment

I am able to see the blob contents in the client window but the file does not show as attachment which is my main purpose-- to give the user the option either to open the file or to save the file on his machine. I am also setting the setHeader as attachment , but nothing happens....and sometimes it shows a dialog box to open my jsp file itself rather than the desired file... sending you the code ..please help
File file1 = new File("c:\\Test.java");
byte[] buffer = new byte[(int)file1.length()];
BufferedInputStream is = new BufferedInputStream(new FileInputStream(file1));
is.read(buffer, 0, (int)file1.length());
is.close();
ByteArrayOutputStream baos = new ByteArrayOutputStream();
baos.write(buffer, 0, (int)file1.length());
System.out.println(baos.toString());
byte[] pass = baos.toByteArray();
response.setHeader("Content-Desposition", "attachment;filename=untitled.java");
response.setContentType("application/octet-stream");
//Send content to Browser
ServletOutputStream servletOut = response.getOutputStream();
servletOut.write(pass);
servletOut.close();

It works,
you have a type!
response.setHeader("Content-Desposition", "attachment;filename=untitled.java");
It should be "Content-Disposition" not "Content-Desposition"
try it out.
cheers

Similar Messages

  • Display BLOB contents to client

    I want to display the blob contents in the clients window and give him the option either to open or save the contents. I am able to read the contents from Oracle Blob Field and stored the contents in the ByteArrayOutputStream object but I am not able to open the contents for the client. I am using the following code
    Blob blob = resultSet.getBlob(1);
    int length = (int)blob.length();
    byte [] b = blob.getBytes(1, length );
    ByteArrayOutputStream baos = new ByteArrayOutputStream();
    baos.write(b,0,length);
    response.setHeader("Content-Disposition","attachment; filename="+baos );
    Please help me

    I am able to see the blob contents in the client window but the file does not show as attachment which is my main purpose-- to give the user the option either to open the file or to save the file on his machine. I am also setting the setHeader as attachment , but nothing happens....and sometimes it shows a dialog box to open my jsp file itself rather than the desired file... sending you the code ..please help
    File file1 = new File("c:\\Test.java");
    byte[] buffer = new byte[(int)file1.length()];
    BufferedInputStream is = new BufferedInputStream(new FileInputStream(file1));
    is.read(buffer, 0, (int)file1.length());
    is.close();
    ByteArrayOutputStream baos = new ByteArrayOutputStream();
    baos.write(buffer, 0, (int)file1.length());
    System.out.println(baos.toString());
    byte[] pass = baos.toByteArray();
    response.setHeader("Content-Desposition", "attachment;filename=untitled.java");
    response.setContentType("application/octet-stream");
    //Send content to Browser
    ServletOutputStream servletOut = response.getOutputStream();
    servletOut.write(pass);
    servletOut.close();

  • Send the auto mail Attachment using client machine outlook application

    Hi all,
    we are using the following EBS & Database
    Database Server
    RDBMS : 11.2.0.3.0
    Oracle Applications : 12.1.2
    i would like to send the file as a attachment using client machine outlook application.
    the(.TXT) file has generated by the concurrent program and stored in the oracle server in specific oracle DB directory path. now my requirement is after generating the file then same file has to send mail to specific mail id using client machine outlook application.can anybody suggest me how to do this
    (i tried to send mail using UTL_SMTP.DATA but this standard procedure is allowing the file attachment size up to KB only.)
    Thanks in advance.

    kknr wrote:
    Hi all,
    we are using the following EBS & Database
    Database Server
    RDBMS : 11.2.0.3.0
    Oracle Applications : 12.1.2
    i would like to send the file as a attachment using client machine outlook application.
    the(.TXT) file has generated by the concurrent program and stored in the oracle server in specific oracle DB directory path. now my requirement is after generating the file then same file has to send mail to specific mail id using client machine outlook application.can anybody suggest me how to do this
    (i tried to send mail using UTL_SMTP.DATA but this standard procedure is allowing the file attachment size up to KB only.)
    Thanks in advance.Please see old threads for the same topic/discussion.
    https://forums.oracle.com/forums/search.jspa?threadID=&q=Send+AND+Email+AND+Attachment+AND+Concurrent&objID=c3&dateRange=all&userID=&numResults=15&rankBy=10001
    https://forums.oracle.com/forums/search.jspa?threadID=&q=Send+AND+Email+AND+Output+AND+Concurrent&objID=c3&dateRange=all&userID=&numResults=15&rankBy=10001
    Thanks,
    Hussein

  • Open & attach word document on clients machine

    I want to open & attach word document on client machine from Oracle Forms, all my trials failed.
    I am using Oracle 10G
    I want detailed steps to do so.
    Best Regards
    Message was edited by:
    user630033

    Hi,
    ... I would ask this question in the Forms-Forum instead of here ...
    Have a look at WebUtil: http://www.oracle.com/technology/products/forms/htdocs/webutil/webutil.htm
    Regards
    Rainer

  • Send 10g reports directly to the default printer of the client machine

    Hello..
    We are using Oracle DS10g and Forms & Reports service 10g. When the user clicks on the report button I want to send the report directly to the default printer installed in the client machine. In this case the printer name may vary and I cannot parameterize the DESNAME parameter. How do i know what is the default printer? Any clue as to how can achieve the desired result?
    Thanks

    If you use webutil in your shop. You can use the CLient_win_api_environment.read_registry to get the default printer. In the run_report_object, desname gets set to the default printer.
    This can also be found in metalink.
                   V_PRINTER := CLIENT_WIN_API_ENVIRONMENT.READ_REGISTRY('HKEY_CURRENT_USER\software\Microsoft\Windows NT\CurrentVersion\Windows','Device',TRUE);
                   V_PRINTER_LENGTH := LENGTH(V_PRINTER);
                   V_PRINTER_BLANK :=     INSTR(V_PRINTER, ',');
                   IF V_PRINTER_LENGTH > 0 AND V_PRINTER_BLANK = 0 THEN
                        :P_OUTPUT_FILE := V_PRINTER;                    
                   ELSIF V_PRINTER_LENGTH > V_PRINTER_BLANK THEN
                   :P_OUTPUT_FILE := SUBSTR(V_PRINTER, 0 , (INSTR(V_PRINTER, ',')-1 ));                    
                   END IF;

  • How i can send blob attachment with smtp email?

    any body can help me how i can send blob file?

    There are lots of example in the web.
    http://blogs.techrepublic.com.com/programming-and-development/?p=517&tag=content;leftCol

  • Send the contents of group to be machine translated.

    I know is possible to send the contents of this term set to be machine translated, but a like to send the group to be machine translated.   Is it possible?

    Hi,
     No, we cannot send the group to be machine translated by OOTB.
    For more information about Machine Translation,you can have a look at the blog:
    http://blogs.technet.com/b/wbaer/archive/2012/11/12/introduction-to-machine-translation-services-in-sharepoint-2013.aspx
    Best Regards,
    Eric
    TechNet Community Support
    Please remember to mark the replies as answers if they help, and unmark the answers if they provide no help. If you have feedback for TechNet Support, contact
    [email protected]

  • Reg :File upload and download from client machine

    hi..
    anyone help me the way that how to upload and download word
    document file from client machine.. i am using j2eeserver1.4 in linux..
    i want upload file from client machine(windows) to server(linux.) please
    help me . tell me idea regarding..
    i have tried this coding.. but i can transfer txt file. only. when i upload mirosoft word file.. it will open with some ascii values with actual content.
    <!-- upload.jsp -->
    <%@ page import="java.io.*" %>
    <%String contentType = request.getContentType();
    String file = "";
    String saveFile = "";
    FileOutputStream fileOut = null;
    if ((contentType != null) && (contentType.indexOf("multipart/form-data") >= 0))
    DataInputStream in = new DataInputStream(request.getInputStream());
    int formDataLength = request.getContentLength();
    byte dataBytes[] = new byte[formDataLength];
    int byteRead = 0;
    int totalBytesRead = 0;
    while (totalBytesRead < formDataLength)
    byteRead = in.read(dataBytes, totalBytesRead, formDataLength);
    totalBytesRead += byteRead;
    try { 
    file = new String(dataBytes);
    saveFile = file.substring(file.indexOf("filename=\"") + 10);
    saveFile = saveFile.substring(0, saveFile.indexOf("\n"));
    saveFile = saveFile.substring(saveFile.lastIndexOf("/") + 1,saveFile.indexOf("\""));
    int lastIndex = contentType.lastIndexOf("=");
    String boundary = contentType.substring(lastIndex + 1,contentType.length());
    int pos;
    pos = file.indexOf("filename=/" + 1);
    pos = file.indexOf("\n", pos) + 1;
    pos = file.indexOf("\n", pos) + 1;
    pos = file.indexOf("\n", pos) + 1;
    int boundaryLocation = file.indexOf(boundary, pos) - 4;
    int startPos = ((file.substring(0, pos)).getBytes()).length;
    int endPos = ((file.substring(0, boundaryLocation)).getBytes()).length;
    String folder = "/tmp/uploads/";
    fileOut = new FileOutputStream(folder + saveFile);
    fileOut.write(dataBytes);
    fileOut.write(dataBytes, startPos, (endPos - startPos));
    fileOut.flush(); } catch(Exception e) {  out.print(e);
    } finally
    {  try
    {fileOut.close();
    }catch(Exception err)
    %>
    please which package will help me to upload word document file with no errror. send me how can use in ftp.. send me some sample program..
    Regards..
    New User M.Senthil..

    Hi,
    Well,i don't know whether if this helps people here are not.
    It is always a good practise to do it via Servlet and then download content.
    The adavantage of doing this is
    1). You may not need to pack the downloadable with the .war which you ultimately genrate which ceratinly help us in terms of faster deployment.
    3). You may update the new content just by moving a file to the backup folder.
    2).One may definately download the content irrespective to the content/file.
    Hope example below helps..
    Configurations:
    In the above example we are assuming that we placing all downlodable file in D:/webapp/downlodables/ and you have configured the same path as a init param with the name "filePath" in your web.xml.
    something like the one below.
    <servlet>
        <servlet-name>DownloadServlet</servlet-name>
        <servlet-class>com.DownloadServlet</servlet-class>
        <init-param>
           <param-name>filePath</param-name>
           <param-value>D:/webapp/downlodables/</param-name>
           <!--Could use any backup folder Available on your Server-->
        </init-param>
    </servlet>
    <servlet-mapping>
        <servlet-name>DownloadServlet</servlet-name>
        <url-pattern>/downloadFile</url-pattern>
    </servlet-mapping>DownloadServlet.java:
    ==================
    package com;
    import javax.servlet.ServletConfig;
    import javax.servlet.ServletException;
    import javax.servlet.http.HttpServlet;
    import javax.servlet.http.HttpServletRequest;
    import javax.servlet.http.HttpServletResponse;
    import java.io.BufferedOutputStream;
    import java.io.File;
    import java.io.FileInputStream;
    import java.io.IOException;
    import javax.activation.MimetypesFileTypeMap;
    *@Author RaHuL
    /**Download Servlet
    *  which could be accessed downloadFile?fid=fileName
    *  or
    *  http://HOST_NAME:APPLN_PORT/ApplnContext/downloadFile?fid=fileName
    public class DownloadServlet extends HttpServlet{
      private static String filePath = new String();
      private static boolean dirExists = false;
      public void init(ServletConfig config){
          // Acquiring Backup Folder Part
          filePath = config.getInitParameter("filePath");
          dirExists = new File(filePath).exists();      
      private void processAction(HttpServletRequest request,HttpServletResponse response) throws Exception{
           // Some Authentication Checks depending upon requirements.
           // getting fileName which user is requesting for
           String fileName = request.getParameter("fid");
           //Building the filePath
           StringBuffer  tFile = new StringBuffer();
           tFile.append(filePath);    
           tFile.append("fileName"); 
           boolean exists = new File(tFile.toString()).exists();
           // Checking whether the file Exists or not      
           if(exists){
            FileInputStream input = null;
            BufferedOutputStream output = null; 
            int contentLength = 0;
            try{
                // Getting the Mime-Type
                String contentType = new MimetypesFileTypeMap().getContentType(tFile.toString());          
                input = new FileInputStream(tFile.toString());
                contentLength = input.available();
                response.setContentType(contentType);
                response.setContentLength(contentLength);
                response.setHeader("Content-Disposition","attachment;filename="+fileName);
                output = new BufferedOutputStream(response.getOutputStream());
                while ( contentLength-- > 0 ) {
                   output.write(input.read());
                 output.flush();
              }catch(IOException e) {
                     System.err.println("Exception Occured:"+e.getMessage());
                 System.err.println("Exception Localized Message:"+e.getLocalizedMessage());
              } finally {
                   if (output != null) {
                       try {
                          output.close();
                      } catch (IOException ie) {
                          System.err.println("Exception Occured:"+e.getMessage());
                             System.err.println("Exception Localized Message:"+e.getLocalizedMessage());                      
           }else{
             response.sendRedirect("/errorPage.html");
      public void doPost(HttpServletRequest request,HttpServletResponse response) throws Exception{       
            processAction(request,response); 
      public void doGet(HttpServletRequest request,HttpServletResponse response) throws Exception{
            processAction(request,response); 
    NOTE: Make sure You include activations.jar in your CLASSPATH b4 trying the code.
    therefore,if you have something like above set as your application enviroment in the above disccussed
    can be done by just giving a simple hyper link like
    <a href="downloadFile?fid=fileName.qxd" target="_blank">Download File</a>REGARDS,
    RaHuL

  • JSP to Upload file from client machine to Web Server!

    Hi,
    I want to upload a file from client machine to web server in order to send it as email attachment, How can I do it? After uploading the file the class should give me the path where the file is stored on the web server and the file name in return!
    I know the HTML <file> field but dont know how to copy it on web server, HTML Part will be:
    <FORM ENCTYPE="multipart/form-data"
    method="POST" action="My.jsp">
    <INPUT TYPE="file" NAME="mptest">
    <INPUT TYPE="submit" VALUE="upload">
    </FORM>
    Please help!
    Thanks,
    - Rahul

    You can use cos.jar provided by O'Reilly from http://www.servlets.com/cos/. Take a look at com.oreilly.servlet.multipart.* classes.
    Package is provided with source, classes, documentation and, of course, ready-to-use jar file.
    It is really usefull and - ready!

  • How to download a file from server machine to client machine using jsp

    Hi,
    In my application, I have an excel file stored on my server machine. How can I download that excel file on to my client machine using jsp. Is there any other way I can open that file from my machine and save it in my machine using jsp/java?
    Its an emergency for me to do this.
    Can anyone provide me the full code to download a file from server machine as I don't have
    time to browse through various sites.
    thanks in advance,
    Tiijnar

    Please post your code using code tags (click on CODE above the text area, when posting)
    response.setContentType("application/octet-stream");Why octet-stream? Set the correct mime-type.
    String disHeader = "Attachment; Filename=\"filename\"";The filename should just be the file's name. Not the complete path to the file! This will tell anyone where the file is located on the server. It's also inconvenient because by default,the browser will suggest it as the name for the download.
    Your way of writing to the output stream is just plain wrong. See this snippet (picked from [http://balusc.blogspot.com/2007/07/fileservlet.html])
            BufferedInputStream input = null;
            BufferedOutputStream output = null;
            try {
                // Open streams.
                input = new BufferedInputStream(new FileInputStream(file), DEFAULT_BUFFER_SIZE);
                output = new BufferedOutputStream(response.getOutputStream(), DEFAULT_BUFFER_SIZE);
                // Write file contents to response.
                byte[] buffer = new byte[DEFAULT_BUFFER_SIZE];
                int length;
                while ((length = input.read(buffer)) > 0) {
                    output.write(buffer, 0, length);
                // Finalize task.
                output.flush();
            } finally {
                // Gently close streams.
                close(output);
                close(input);
            }

  • Client machine not reporting to wsus server

    My server Windows Server 2008 R2 Standard x 64 virtual machine install in Hyper-v server and Install SCE management version 2010.
    in sudden server stopped sending updated to client machine. So I check many and did many changed as per MS community forums. But still I have same issue. 
    Then I planned to install again SCE management server in different VM. But even though I am getting error that old SCE management server is existing in my domain.  Therefore I am afraid to change or remove any setting in AD since I have short
    of knowledge about SCE servers. 
    However my SCE server was working smoothly until 11-2013 and then suddenly stuck. When I check the server machine I found that local drive C: is getting full and SCE management is fail to start. So from that to now when ever I had free time I changed
    many things. But unfortunately I couldn't get the sever back to normal.
    Few changes which I made are below.
    - Remove and reinstall WAUS several times
    - Check online update and direct updated server SCE machine without getting updated from SCE
    - Remove dotnet frame work and updated version 4
    - product configuration wizard reconfigure
    - Repair management agent in client machine.
    Kindly help for me to repair my SCE server or make another installation without having change of settings.
    It would be highly appreciated if you could resolve issue
    The error massage is below in windows update log.
    2015-02-11 11:37:46:747 904 c78 Misc =========== Logging initialized (build: 7.6.7600.320, tz: +0300) ===========
    2015-02-11 11:37:46:747 904 c78 Misc = Process: C:\Windows\system32\svchost.exe
    2015-02-11 11:37:46:747 904 c78 Misc = Module: c:\windows\system32\wuaueng.dll
    2015-02-11 11:37:46:747 904 c78 Service *************
    2015-02-11 11:37:46:747 904 c78 Service ** START ** Service: Service startup
    2015-02-11 11:37:46:747 904 c78 Service *********
    2015-02-11 11:37:46:750 904 c78 Agent * WU client version 7.6.7600.320
    2015-02-11 11:37:46:750 904 c78 Agent * Base directory: C:\Windows\SoftwareDistribution
    2015-02-11 11:37:46:750 904 c78 Agent * Access type: No proxy
    2015-02-11 11:37:46:751 904 c78 Agent * Network state: Connected
    2015-02-11 11:37:58:940 904 8a0 Report CWERReporter::Init succeeded
    2015-02-11 11:37:58:940 904 8a0 Agent *********** Agent: Initializing Windows Update Agent ***********
    2015-02-11 11:37:58:941 904 8a0 Agent * Prerequisite roots succeeded.
    2015-02-11 11:37:58:941 904 8a0 Agent *********** Agent: Initializing global settings cache ***********
    2015-02-11 11:37:58:941 904 8a0 Agent * WSUS server: http://SCE-01.mubarrad.com.kw:8530
    2015-02-11 11:37:58:941 904 8a0 Agent * WSUS status server: http://SCE-01.mubarrad.com.kw:8530
    2015-02-11 11:37:58:941 904 8a0 Agent * Target group: (Unassigned Computers)
    2015-02-11 11:37:58:941 904 8a0 Agent * Windows Update access disabled: No
    2015-02-11 11:37:59:068 904 8a0 DnldMgr Download manager restoring 0 downloads
    2015-02-11 11:37:59:081 904 8a0 AU ########### AU: Initializing Automatic Updates ###########
    2015-02-11 11:37:59:082 904 8a0 AU # WSUS server: http://SCE-01.mubarrad.com.kw:8530
    2015-02-11 11:37:59:082 904 8a0 AU # Detection frequency: 22
    2015-02-11 11:37:59:082 904 8a0 AU # Approval type: Pre-install notify (Policy)
    2015-02-11 11:37:59:082 904 8a0 AU # Auto-install minor updates: No (User preference)
    2015-02-11 11:37:59:082 904 8a0 AU # Will interact with non-admins (Non-admins are elevated (User preference))
    2015-02-11 11:37:59:082 904 8a0 AU # Will display featured software notifications (User preference)
    2015-02-11 11:37:59:301 904 c78 Report *********** Report: Initializing static reporting data ***********
    2015-02-11 11:37:59:301 904 c78 Report * OS Version = 6.1.7601.1.0.196880
    2015-02-11 11:37:59:301 904 c78 Report * OS Product Type = 0x00000007
    2015-02-11 11:37:59:313 904 c78 Report * Computer Brand = Microsoft Corporation
    2015-02-11 11:37:59:313 904 c78 Report * Computer Model = Virtual Machine
    2015-02-11 11:37:59:316 904 c78 Report * Bios Revision = 090004
    2015-02-11 11:37:59:316 904 c78 Report * Bios Name = BIOS Date: 03/19/09 22:51:32 Ver: 09.00.04
    2015-02-11 11:37:59:316 904 c78 Report * Bios Release Date = 2009-03-19T00:00:00
    2015-02-11 11:37:59:316 904 c78 Report * Locale ID = 1033
    2015-02-11 11:37:59:352 904 8a0 AU Successfully wrote event for AU health state:0
    2015-02-11 11:37:59:352 904 8a0 AU Initializing featured updates
    2015-02-11 11:37:59:352 904 8a0 AU Found 0 cached featured updates
    2015-02-11 11:37:59:352 904 8a0 AU Successfully wrote event for AU health state:0
    2015-02-11 11:37:59:353 904 8a0 AU Successfully wrote event for AU health state:0
    2015-02-11 11:37:59:354 904 8a0 AU AU finished delayed initialization
    2015-02-11 11:37:59:354 904 c78 AU #############
    2015-02-11 11:37:59:354 904 c78 AU ## START ## AU: Search for updates
    2015-02-11 11:37:59:354 904 c78 AU #########
    2015-02-11 11:37:59:356 904 c78 AU <<## SUBMITTED ## AU: Search for updates [CallId = {A05977D0-8D58-4DC1-AAC5-C5FD68987D7F}]
    2015-02-11 11:38:01:818 904 8a0 AU Triggering AU detection through DetectNow API
    2015-02-11 11:38:01:818 904 8a0 AU Will do the detection after current detection completes
    2015-02-11 11:38:03:808 904 1de0 Misc WARNING: Send failed with hr = 80072efd.
    2015-02-11 11:38:03:808 904 1de0 Misc WARNING: SendRequest failed with hr = 80072efd. Proxy List used: <(null)> Bypass List used : <(null)> Auth Schemes used : <>
    2015-02-11 11:38:03:808 904 1de0 Misc FATAL: SOAP/WinHttp - SendRequest: SendRequestUsingProxy failed. error 0x80072efd
    2015-02-11 11:38:03:808 904 1de0 PT + Last proxy send request failed with hr = 0x80072EFD, HTTP status code = 0
    2015-02-11 11:38:03:808 904 1de0 PT + Caller provided credentials = No
    2015-02-11 11:38:03:808 904 1de0 PT + Impersonate flags = 0
    2015-02-11 11:38:03:808 904 1de0 PT + Possible authorization schemes used =
    2015-02-11 11:38:03:808 904 1de0 PT WARNING: GetConfig failure, error = 0x80072EFD, soap client error = 5, soap error code = 0, HTTP status code = 200
    2015-02-11 11:38:03:808 904 1de0 PT WARNING: PTError: 0x80072efd
    2015-02-11 11:38:03:808 904 1de0 PT WARNING: GetConfig_WithRecovery failed: 0x80072efd
    2015-02-11 11:38:03:808 904 1de0 PT WARNING: RefreshConfig failed: 0x80072efd
    2015-02-11 11:38:03:808 904 1de0 PT WARNING: RefreshPTState failed: 0x80072efd
    2015-02-11 11:38:03:808 904 1de0 PT WARNING: PTError: 0x80072efd
    2015-02-11 11:38:03:808 904 1de0 Report WARNING: Reporter failed to upload events with hr = 80072efd.
    2015-02-11 11:38:08:092 904 1de0 Misc WARNING: Send failed with hr = 80072efd.
    2015-02-11 11:38:08:092 904 1de0 Misc WARNING: SendRequest failed with hr = 80072efd. Proxy List used: <(null)> Bypass List used : <(null)> Auth Schemes used : <>
    2015-02-11 11:38:08:092 904 1de0 Misc FATAL: SOAP/WinHttp - SendRequest: SendRequestUsingProxy failed. error 0x80072efd
    2015-02-11 11:38:08:092 904 1de0 PT + Last proxy send request failed with hr = 0x80072EFD, HTTP status code = 0
    2015-02-11 11:38:08:092 904 1de0 PT + Caller provided credentials = No
    2015-02-11 11:38:08:092 904 1de0 PT + Impersonate flags = 0
    2015-02-11 11:38:08:092 904 1de0 PT + Possible authorization schemes used =
    2015-02-11 11:38:08:092 904 1de0 PT WARNING: GetConfig failure, error = 0x80072EFD, soap client error = 5, soap error code = 0, HTTP status code = 200
    2015-02-11 11:38:08:092 904 1de0 PT WARNING: PTError: 0x80072efd
    2015-02-11 11:38:08:092 904 1de0 PT WARNING: GetConfig_WithRecovery failed: 0x80072efd
    2015-02-11 11:38:08:092 904 1de0 PT WARNING: RefreshConfig failed: 0x80072efd
    2015-02-11 11:38:08:092 904 1de0 PT WARNING: RefreshPTState failed: 0x80072efd
    2015-02-11 11:38:08:092 904 1de0 PT WARNING: PTError: 0x80072efd
    2015-02-11 11:38:08:092 904 1de0 Report WARNING: Reporter failed to upload events with hr = 80072efd.
    2015-02-11 11:38:08:093 904 1de0 Report REPORT EVENT: {62417852-380A-47BC-B153-8A8E0E198470} 2015-02-11 11:37:59:352+0300 1 202 102 {00000000-0000-0000-0000-000000000000} 0 0 AutomaticUpdates Success Content Install Reboot completed.
    2015-02-11 11:38:08:098 904 1de0 Report CWERReporter finishing event handling. (00000000)
    2015-02-11 11:38:08:098 904 1de0 Agent *************
    2015-02-11 11:38:08:098 904 1de0 Agent ** START ** Agent: Finding updates [CallerId = AutomaticUpdates]
    2015-02-11 11:38:08:098 904 1de0 Agent *********
    2015-02-11 11:38:08:098 904 1de0 Agent * Online = No; Ignore download priority = No
    2015-02-11 11:38:08:098 904 1de0 Agent * Criteria = "IsInstalled=0 and DeploymentAction='Installation' or IsPresent=1 and DeploymentAction='Uninstallation' or IsInstalled=1 and DeploymentAction='Installation' and RebootRequired=1 or IsInstalled=0 and DeploymentAction='Uninstallation' and RebootRequired=1"
    2015-02-11 11:38:08:098 904 1de0 Agent * ServiceID = {3DA21691-E39D-4DA6-8A4B-B43877BCB1B7} Managed
    2015-02-11 11:38:08:098 904 1de0 Agent * Search Scope = {Machine}
    2015-02-11 11:38:08:440 904 1de0 Agent * Found 0 updates and 0 categories in search; evaluated appl. rules of 0 out of 0 deployed entities
    2015-02-11 11:38:08:441 904 1de0 Agent *********
    2015-02-11 11:38:08:441 904 1de0 Agent ** END ** Agent: Finding updates [CallerId = AutomaticUpdates]
    2015-02-11 11:38:08:441 904 1de0 Agent *************
    2015-02-11 11:38:08:441 904 edc AU >>## RESUMED ## AU: Search for updates [CallId = {A05977D0-8D58-4DC1-AAC5-C5FD68987D7F}]
    2015-02-11 11:38:08:441 904 edc AU # 0 updates detected
    2015-02-11 11:38:08:441 904 edc AU #########
    2015-02-11 11:38:08:441 904 edc AU ## END ## AU: Search for updates [CallId = {A05977D0-8D58-4DC1-AAC5-C5FD68987D7F}]
    2015-02-11 11:38:08:441 904 edc AU #############
    2015-02-11 11:38:08:441 904 edc AU Featured notifications is disabled.
    2015-02-11 11:38:08:442 904 edc AU Successfully wrote event for AU health state:0
    2015-02-11 11:38:08:442 904 edc AU Successfully wrote event for AU health state:0
    2015-02-11 11:38:08:442 904 c78 AU #############
    2015-02-11 11:38:08:442 904 c78 AU ## START ## AU: Search for updates
    2015-02-11 11:38:08:442 904 c78 AU #########
    2015-02-11 11:38:08:444 904 c78 AU <<## SUBMITTED ## AU: Search for updates [CallId = {B8E1001D-5C48-4A26-888D-99FECCD6F9F1}]
    2015-02-11 11:38:08:444 904 1de0 Agent *************
    2015-02-11 11:38:08:444 904 1de0 Agent ** START ** Agent: Finding updates [CallerId = AutomaticUpdates]
    2015-02-11 11:38:08:444 904 1de0 Agent *********
    2015-02-11 11:38:08:444 904 1de0 Agent * Online = Yes; Ignore download priority = No
    2015-02-11 11:38:08:444 904 1de0 Agent * Criteria = "IsInstalled=0 and DeploymentAction='Installation' or IsPresent=1 and DeploymentAction='Uninstallation' or IsInstalled=1 and DeploymentAction='Installation' and RebootRequired=1 or IsInstalled=0 and DeploymentAction='Uninstallation' and RebootRequired=1"
    2015-02-11 11:38:08:444 904 1de0 Agent * ServiceID = {3DA21691-E39D-4DA6-8A4B-B43877BCB1B7} Managed
    2015-02-11 11:38:08:444 904 1de0 Agent * Search Scope = {Machine}
    2015-02-11 11:38:08:444 904 1de0 Setup Checking for agent SelfUpdate
    2015-02-11 11:38:08:445 904 1de0 Setup Client version: Core: 7.6.7600.320 Aux: 7.6.7600.320
    2015-02-11 11:38:12:726 904 1de0 Misc WARNING: Send failed with hr = 80072efd.
    2015-02-11 11:38:12:726 904 1de0 Misc WARNING: SendRequest failed with hr = 80072efd. Proxy List used: <(null)> Bypass List used : <(null)> Auth Schemes used : <>
    2015-02-11 11:38:12:726 904 1de0 Misc WARNING: WinHttp: SendRequestUsingProxy failed for <http://SCE-01.mubarrad.com.kw:8530/selfupdate/wuident.cab>. error 0x80072efd
    2015-02-11 11:38:12:726 904 1de0 Misc WARNING: WinHttp: SendRequestToServerForFileInformation MakeRequest failed. error 0x80072efd
    2015-02-11 11:38:12:726 904 1de0 Misc WARNING: WinHttp: SendRequestToServerForFileInformation failed with 0x80072efd
    2015-02-11 11:38:12:726 904 1de0 Misc WARNING: WinHttp: ShouldFileBeDownloaded failed with 0x80072efd
    2015-02-11 11:38:16:993 904 1de0 Misc WARNING: Send failed with hr = 80072efd.
    2015-02-11 11:38:16:993 904 1de0 Misc WARNING: SendRequest failed with hr = 80072efd. Proxy List used: <(null)> Bypass List used : <(null)> Auth Schemes used : <>
    2015-02-11 11:38:16:993 904 1de0 Misc WARNING: WinHttp: SendRequestUsingProxy failed for <http://SCE-01.mubarrad.com.kw:8530/selfupdate/wuident.cab>. error 0x80072efd
    2015-02-11 11:38:16:993 904 1de0 Misc WARNING: WinHttp: SendRequestToServerForFileInformation MakeRequest failed. error 0x80072efd
    2015-02-11 11:38:16:993 904 1de0 Misc WARNING: WinHttp: SendRequestToServerForFileInformation failed with 0x80072efd
    2015-02-11 11:38:16:993 904 1de0 Misc WARNING: WinHttp: ShouldFileBeDownloaded failed with 0x80072efd
    2015-02-11 11:38:21:278 904 1de0 Misc WARNING: Send failed with hr = 80072efd.
    2015-02-11 11:38:21:278 904 1de0 Misc WARNING: SendRequest failed with hr = 80072efd. Proxy List used: <(null)> Bypass List used : <(null)> Auth Schemes used : <>
    2015-02-11 11:38:21:278 904 1de0 Misc WARNING: WinHttp: SendRequestUsingProxy failed for <http://SCE-01.mubarrad.com.kw:8530/selfupdate/wuident.cab>. error 0x80072efd
    2015-02-11 11:38:21:278 904 1de0 Misc WARNING: WinHttp: SendRequestToServerForFileInformation MakeRequest failed. error 0x80072efd
    2015-02-11 11:38:21:278 904 1de0 Misc WARNING: WinHttp: SendRequestToServerForFileInformation failed with 0x80072efd
    2015-02-11 11:38:21:278 904 1de0 Misc WARNING: WinHttp: ShouldFileBeDownloaded failed with 0x80072efd
    2015-02-11 11:38:25:564 904 1de0 Misc WARNING: Send failed with hr = 80072efd.
    2015-02-11 11:38:25:564 904 1de0 Misc WARNING: SendRequest failed with hr = 80072efd. Proxy List used: <(null)> Bypass List used : <(null)> Auth Schemes used : <>
    2015-02-11 11:38:25:564 904 1de0 Misc WARNING: WinHttp: SendRequestUsingProxy failed for <http://SCE-01.mubarrad.com.kw:8530/selfupdate/wuident.cab>. error 0x80072efd
    2015-02-11 11:38:25:564 904 1de0 Misc WARNING: WinHttp: SendRequestToServerForFileInformation MakeRequest failed. error 0x80072efd
    2015-02-11 11:38:25:564 904 1de0 Misc WARNING: WinHttp: SendRequestToServerForFileInformation failed with 0x80072efd
    2015-02-11 11:38:25:564 904 1de0 Misc WARNING: WinHttp: ShouldFileBeDownloaded failed with 0x80072efd
    2015-02-11 11:38:25:564 904 1de0 Misc WARNING: DownloadFileInternal failed for http://SCE-01.mubarrad.com.kw:8530/selfupdate/wuident.cab: error 0x80072efd
    2015-02-11 11:38:25:564 904 1de0 Setup FATAL: DownloadCab failed, err = 0x80072EFD
    2015-02-11 11:38:25:564 904 1de0 Setup WARNING: SelfUpdate check failed to download package information, error = 0x80072EFD
    2015-02-11 11:38:25:564 904 1de0 Setup FATAL: SelfUpdate check failed, err = 0x80072EFD
    2015-02-11 11:38:25:565 904 1de0 Agent * WARNING: Skipping scan, self-update check returned 0x80072EFD
    2015-02-11 11:38:25:565 904 1de0 Agent * WARNING: Exit code = 0x80072EFD
    2015-02-11 11:38:25:565 904 1de0 Agent *********
    2015-02-11 11:38:25:565 904 1de0 Agent ** END ** Agent: Finding updates [CallerId = AutomaticUpdates]
    2015-02-11 11:38:25:565 904 1de0 Agent *************
    2015-02-11 11:38:25:565 904 1de0 Agent WARNING: WU client failed Searching for update with error 0x80072efd
    2015-02-11 11:38:25:565 904 1de0 Report CWERReporter finishing event handling. (00000000)
    2015-02-11 11:38:25:565 904 edc AU >>## RESUMED ## AU: Search for updates [CallId = {B8E1001D-5C48-4A26-888D-99FECCD6F9F1}]
    2015-02-11 11:38:25:566 904 edc AU # WARNING: Search callback failed, result = 0x80072EFD
    2015-02-11 11:38:25:566 904 edc AU # WARNING: Failed to find updates with error code 80072EFD
    2015-02-11 11:38:25:566 904 edc AU #########
    2015-02-11 11:38:25:566 904 edc AU ## END ## AU: Search for updates [CallId = {B8E1001D-5C48-4A26-888D-99FECCD6F9F1}]
    2015-02-11 11:38:25:566 904 edc AU #############
    2015-02-11 11:38:25:566 904 edc AU Successfully wrote event for AU health state:0
    2015-02-11 11:38:25:566 904 edc AU AU setting next detection timeout to 2015-02-11 13:38:25
    2015-02-11 11:38:25:566 904 edc AU Successfully wrote event for AU health state:0
    2015-02-11 11:38:25:567 904 edc AU Successfully wrote event for AU health state:0
    2015-02-11 11:38:30:595 904 1de0 Report REPORT EVENT: {6470B8FE-1600-4F7B-807F-6031606ECC8B} 2015-02-11 11:38:25:564+0300 1 148 101 {D67661EB-2423-451D-BF5D-13199E37DF28} 1 80072efd SelfUpdate Failure Software Synchronization Windows Update Client failed to detect with error 0x80072efd.
    2015-02-11 11:38:30:613 904 1de0 Report CWERReporter::HandleEvents - WER report upload completed with status 0x8
    2015-02-11 11:38:30:613 904 1de0 Report WER Report sent: 7.6.7600.320 0x80072efd D67661EB-2423-451D-BF5D-13199E37DF28 Scan 101 Managed
    2015-02-11 11:38:30:613 904 1de0 Report CWERReporter finishing event handling. (00000000)

    Can you try the below to reset the authorization and force a connection back from one of the win 7 machines:
    it should help pinpoint exact issues. 
    1. Record the system time.
    2. Reboot the system (or restart the Windows Update service).
    3. After reboot run the command wuauclt
    /resetauthorization /detectnow.
    4. Wait 30 minutes.
    5. Post the entries from the WindowsUpdate.log starting at the time recorded in Step #1.
    Do you have any Windows 7 machines that are reporting? Are other machines with different operating systems reporting correctly?

  • Group Policy not work in some client machine.

    Hello All,
    Existing environment is AD 2012. gpupdate /force command does not working in some client machine. And it's occur randomly. Error shown about 15-20% of client machine. Please suggest. Hopefully this time get reply from community.
    The Error:
    User policy could not be updated successfully. The following errors were encount
    ered:
    The processing of Group Policy failed. Windows attempted to read the file \\example.net\sysvol\example.net\Policies\{31B2F340-016D-11D2-945F-00C04FB
    984F9}\gpt.ini from a domain controller and was not successful. Group Policy set
    tings may not be applied until this event is resolved. This issue may be transie
    nt and could be caused by one or more of the following:
    a) Name Resolution/Network Connectivity to the current domain controller.
    b) File Replication Service Latency (a file created on another domain controller
     has not replicated to the current domain controller).
    c) The Distributed File System (DFS) client has been disabled.
    Computer policy could not be updated successfully. The following errors were enc
    ountered:
    The processing of Group Policy failed. Windows attempted to read the file \\example.net\sysvol\example.net\Policies\{31B2F340-016D-11D2-945F-00C04FB
    984F9}\gpt.ini from a domain controller and was not successful. Group Policy set
    tings may not be applied until this event is resolved. This issue may be transie
    nt and could be caused by one or more of the following:
    a) Name Resolution/Network Connectivity to the current domain controller.

    Thanks for your reply. basically this error occurs with in same location as well as branch location. i have check event log in AD but not got any specific error. AD health status is ok. AD to AD synchronization also working well. All the client machine running
    on windows 7 64 bit and few of them are windows 8. 
    Please suggest. if you need any event log for analysis i can send you.
    Thanks
    I recommend you examine the event logs upon an affected client machine. Specifically, look for the surrounding events on that machine (both System, and Application logs), for the hours previous and the hour after.
    The time period may vary according to your environment (e.g. what is expected/normal for your environment, your configured GP refresh cycle-time).
    e.g., are there network drops, or power drops, or system crashes, restarts at the similar time.
    if it's a laptop, is it wireless? Was there a transition from wireless to wired operation?
    Is there VPN in use?
    If you are able to compare with another machine (I would encourage that), to understand what "normal" looks like in the logs, so that you have some kind of baseline data for comparison.
    Other checks, maybe confirm that the machines are updating as required (have the relevant WindowsUpdates etc), and consider if some security/protection/firewall software might be interfering with normal Windows operations.
    Also the potential for malware or virus, which can disturb many basic services (ensure a scan is performed and returns clean).
    If you have the opportunity for an affected user to contact you urgently when the symptom occurs, check that the gpt.ini file is accessible from their PC.
    e.g.: \\example.net\sysvol\example.net\Policies\{31B2F340-016D-11D2-945F-00C04FB
    984F9}\gpt.ini
    This file is hosted within the replicated SYSVOL share on your DC's, so check that it is accessible.
    You might also validate the particular GPO this refers to, and check each of your DC's holds the correct copy of the files for that GPO GUID.
    If you open that GPO, and perform a minor change to it (e.g. add a comment), then click Apply, OK, this should cause the GPO contents to replicate an updated version (be cautious, depending upon the nature of that GPO !!!)
    Don
    (Please take a moment to "Vote as Helpful" and/or "Mark as Answer", where applicable.
    This helps the community, keeps the forums tidy, and recognises useful contributions. Thanks!)

  • Downloading blob content from a custom table

    In our hosted Apex application, the following code from the Application Express Developer's Guide works great for allowing a user to download blob content from one of our custom tables via a download button. However, the code doesn't work on the Oracle Cloud because the "owa_util" package is no longer available. The code is as follows:
    CREATE OR REPLACE PROCEDURE download_my_file(p_file in number) AS
    v_mime VARCHAR2(48);
    v_length NUMBER;
    v_file_name VARCHAR2(2000);
    Lob_loc BLOB;
    BEGIN
    SELECT MIME_TYPE, BLOB_CONTENT, name,DBMS_LOB.GETLENGTH(blob_content)
    INTO v_mime,lob_loc,v_file_name,v_length
    FROM file_subjects
    WHERE id = p_file;
    -- set up HTTP header
    -- use an NVL around the mime type and
    -- if it is a null set it to application/octect
    -- application/octect may launch a download window from windows
    owa_util.mime_header( nvl(v_mime,'application/octet'), FALSE );
    -- set the size so the browser knows how much to download
    htp.p('Content-length: ' || v_length);
    -- the filename will be used by the browser if the users does a save as
    htp.p('Content-Disposition: attachment; filename="'||replace(replace(substr(v_file_name,instr(v_file_name,'/')+1),chr(10),null),chr(13),null)|| '"');
    -- close the headers
    owa_util.http_header_close;
    -- download the BLOB
    wpg_docload.download_file( Lob_loc );
    end download_my_file;
    Besides using web services, does anyone know of a way to do this? Is there a way to add access to the "owa_util" package in the cloud? I have also tried apex_util.get_blob_file_src but that is also unavailable in the Oracle Cloud.
    Thanks,
    Steve

    Following Joel's advice:
    The way I solved this was to split the code between two page processes and one application process. The download button first calls a page process to move the report data into a blob column and then calls another page process which is of "run application process" type. This calls the application level process where the download code, shown below, is called.
    Notice the following changes to the code from the one posted earlier (also from Joel)
    1) added sys.htp.init;
    2) "sys." to all htp, owa and wpg_docload calls
    3) added apex_application.stop_apex_engine; after the wpg_docload statement at the bottom of the script.
    Now the download button launches a "save as" dialog box and the report content is downloaded to the client.
    The code now looks like:
    CREATE OR REPLACE PROCEDURE download_my_file(p_file in number) AS
    v_mime VARCHAR2(48);
    v_length NUMBER;
    v_file_name VARCHAR2(2000);
    Lob_loc BLOB;
    BEGIN
    SELECT MIME_TYPE, BLOB_CONTENT, name,DBMS_LOB.GETLENGTH(blob_content)
    INTO v_mime,lob_loc,v_file_name,v_length
    FROM oehr_file_subject
    WHERE id = p_file;
    -- set up HTTP header
    -- use an NVL around the mime type and
    -- if it is a null set it to application/octect
    -- application/octect may launch a download window from windows
    sys.htp.init;
    sys.owa_util.mime_header( nvl(v_mime,'application/octet'), FALSE );
    -- set the size so the browser knows how much to download
    sys.htp.p('Content-length: ' || v_length);
    -- the filename will be used by the browser if the users does a save as
    sys. htp.p('Content-Disposition: attachment; filename="'||replace(replace(substr(v_file_name,instr(v_file_name,'/')+1),chr(10),null),chr(13),null)|| '"');
    -- close the headers
    sys.owa_util.http_header_close;
    -- download the BLOB
    sys.wpg_docload.download_file( Lob_loc );
    apex_application.stop_apex_engine;
    end download_my_file;
    Thanks Joel for your help.
    Steve

  • Saving Files in Client machine

    Hi,
    Iam generating a servlet application to save reports,
    For this i created a browse button where user can specify the system path.
    when the user clicks save the reports should be saved in specified path of client machine..
    some how am not able to save in client machine(Windows).Its getting saved in server ..
    Please suggest any solution,
    Thanks
    Shriya

    You're using java.io to write to local disk? This is indeed not going to work :)
    Provide it as file download. Set the content disposition to attachment and write the binary file contents to the outputstream of the response. You may find this example useful: [http://balusc.blogspot.com/2007/07/fileservlet.html].

  • JSP Writing to file on the client machine

    Hi Java Gurus,
    I would like to know if it's possible to store (save) information to a file on a client machine from a JSP Application?
    Or let me know good tips to save some data on the client machine... Thanks a lot!
    Nalee

    Hi Gallegux,
    Sorry, I don't mean to sound dense. Here is my JSP page. Do you mean physically on the same line or logically on the same line?
    <%response.setHeader ("Content-Disposition","attachment;filename=xxx.txt"); %>
    <%@ page import="java.sql.*" %>
    <%@ page extends="someone.taglib.servlet.MyDialogServlet" %>
    <%@ page contentType="application/save; charset=iso-8859-1" language="java" import=""%>
    <%@ page import="MyProductBean" %>
    .....body of JSP........
    Thanks so much!

Maybe you are looking for