How to create Excel file in client system...

please tell me,
how to create a excel file in the client system. in my application i am displaying the report from database. my requirement is to create that report in excel format that should be stored in client machine...

http://jakarta.apache.org/poi/
One of the best solution.....

Similar Messages

  • How to Create Excel File in Background processing with different colors

    HI All
    I am trying to create Excel file in background & send it to user through e-mail, this i could acheive using fucntion module SO_DOCUMENT_SEND_API1, but here my requirement is i want to put different colors to columns of excel & this should happen in Background processing,
    Initially i completed above requirement by using HTML type of document with attachment type 'ALI'  & formatted output using write statement & used colors, after that i took this o/p using save_list function module & then table compress...etc.
    but i don't know how to achieve same if we need o/p in excel as size of object of excel file is less than that of HTML
    I am thankfull to everybody who will help me.
    Regards
    Lokesh

    Lokesh,
    Iam also trying to populate my text file with colors as an attachment . If you know this please let me know.

  • Creating excel file on client machine using oracle pl/sql code

    Hi All,
    I have a situation where in i need to create an excel output file in my client machine, but using UTL_FILE i understood that i need to create the directory on server and i need to read and write on server itself.
    Is there any other way where we can create a excel file other than oracle server, bcos this is used only once and there is no scheduler to execute on server.
    Please do the needful.
    Thanks,
    Santhosh.S

    santhosh.shivaram wrote:
    I have a situation where in i need to create an excel output file in my client machine, but using UTL_FILE i understood that i need to create the directory on server and i need to read and write on server itself.I would say that you only need to to look at basic client-server architecture - what is the client component responsible for and what is the server component responsible for.
    The server should create the data set required by the client - do all the (intense) server processing that servers do well. This data set is then send to the client. The client is responsible for rendering that data set.. or saving it to the client machine storage if needed.
    Within PL/SQL that is quite easy to do using the most common/standard client-server in use today - web based client-server.
    The client is a web browser. It makes a call to the web server, that is serviced by a PL/SQL database procedure - a so-called web enabled procedure. It processes the request from the web browser, and returns a dynamic response. This response can range from HTML and XML, to video and image streams - and also CSV (Character Separated Values) data.
    By default, most web browsers will use the local client spreadsheet application (like MS Excel) to open the CSV response received. Many web browsers will also provide an alternate option of saving that response as a CSV file (that can then be opened later using MS Excel).
    Straight forward and basic client-server - and easily done using PL/SQL. Even easier done using (freeware) Oracle APEX (Application Express). APEX is a PL/SQL software suite that provides a web development system (only web browser required for development) and a run-time system to run the web application you have created.

  • How to save a file in client system?

    I have a requiremnet like this:
    "When the user selects a file from his local drive (say c:\), I have to upload the file to a LAN connected to his machine."
    I have written the TestUpload class like below. It will work if my server is on the same machine. But, how can i do this if it is Unix Server?
    I was trying to do this for 2-3 days. Please help.
    protected void doGet(
    HttpServletRequest request, HttpServletResponse response)
    throws ServletException, IOException {
    PrintWriter out = response.getWriter();
    HttpSession session = null;
    UploadListener listener = null;
    long contentLength = 0;
    System.out.println("I am inside doGet");
    if (
    ((session = request.getSession()) == null) ||
    listener =
    (UploadListener) session.getAttribute("LISTENER")
    ) == null
    ) || ((contentLength = listener.getContentLength()) < 1)) {
    out.write("");
    out.close();
    return;
    response.setContentType("text/html");
    long percentComplite =
    ((100 * listener.getBytesRead()) / contentLength);
    out.print(percentComplite);
    out.close();
    protected void doPost(
    HttpServletRequest request, HttpServletResponse response)
    throws ServletException, IOException {
    response.setContentType("text/html");
    // create file upload factory and upload servlet
    FileItemFactory factory = new DiskFileItemFactory();
    ServletFileUpload upload = new ServletFileUpload(factory);
    // set file upload progress listener
    UploadListener listener = new UploadListener();
    HttpSession session = request.getSession();
    session.setAttribute("LISTENER", listener);
    // upload servlet allows to set upload listener
    upload.setProgressListener(listener);
    List items = null;
    FileItem fileItem = null;
    String filename = null;
    String fileName = null;
    String directory = null;
    String version = null;
    String fullPath = null;
    String extension = null;
    String folderName = null;
    try {
    // iterate over all uploaded files
    items = upload.parseRequest(request);
    for (Iterator i = items.iterator(); i.hasNext();) {
    fileItem = (FileItem) i.next();
    System.out.println("New file Item::: " + fileItem.getName());
    if (
    (fileItem.getName() != null) &&
    !fileItem.getName()
    .trim()
    .equals("")) {
    fullPath = fileItem.getName();
    extension = fullPath.substring(fullPath.lastIndexOf("."));
    directory = "\\\\MyLAN\\";
    fileName =
    fullPath.substring(
    fullPath.lastIndexOf("\\") + 1,
    fullPath.lastIndexOf("."));
    folderName = getFolderName(directory, fileName, extension);
    version =
    getVersionNumber(
    directory + folderName, fileName, extension);
    String strFilePath =
    directory + folderName + fileName + version +
    extension;
    System.out.println("path:: " + strFilePath);
              //Creating the destination File object.
    File file = new File(strFilePath);
    if (!fileItem.isFormField()) {
    if (fileItem.getSize() > 0) {
    // code that handle uploaded fileItem
    // don't forget to delete uploaded files after you done with them! Use fileItem.delete();
    fileItem.write(file);
    fileItem.delete();
                                       System.out.println("upload successful");
    // indicate that the upload was successfull
    writeLog(
    directory + folderName + "log.txt",
    now() + " ::: " + "Uploaded the version number:: " + version);
    response.getWriter()
    .write("upload successful");
    } catch (FileUploadException e) {
    response.getWriter()
    .write(e.getMessage());
    e.printStackTrace();
    } catch (Exception e) {
    response.getWriter()
    .write(e.getMessage());
    e.printStackTrace();
    } finally {
    session.removeAttribute("LISTENER");
    public String getFolderName(
    String directory, String fileName, String extension) {
    File dir = new File(directory);
    boolean folderFound = false;
    String foldername = null;
    String logFileName = "";
    File getFolderNames[] = dir.listFiles();
    for (int i = 0; i < getFolderNames.length; i++) {
    foldername = getFolderNames.getName();
    if (foldername.equalsIgnoreCase(fileName)) {
    folderFound = true;
    break;
    if (!folderFound) {
    File f = new File(directory + fileName);
    f.mkdir();
    f = new File(directory + fileName + "/log.txt");
    try {
    f.createNewFile();
    } catch (IOException e) {
    e.printStackTrace();
    logFileName = directory + fileName + "/log.txt";
    writeLog(logFileName, "***********************************");
    writeLog(logFileName, "Log for the file " + fileName);
    writeLog(logFileName, "***********************************\n\n");
    writeLog(logFileName, now() + " ::: " + "Created");
    return fileName + "\\";
    public String getVersionNumber(
    String directory, String fileName, String extension) {
    File dir = new File(directory);
    boolean fileFound = false;
    int version = 0;
    File getFolderNames[] = dir.listFiles();
    version = getFolderNames.length;
    return "_" + version;
    public void writeLog(String fileName, String text) {
    try {
    Writer output = null;
    File file = new File(fileName);
    output = new BufferedWriter(new FileWriter(fileName, true));
    output.write(text + "\n");
    output.close();
    System.out.println("Log file has been written");
    } catch (IOException e1) {
    e1.printStackTrace();
    Edited by: AnishThomas on Mar 12, 2008 10:52 PM

    Thanks for your reply!!!
    jwenting wrote:
    no, your code is NOT correct.
    It doesn't "upload" anything, as I stated before.It is working perfectly fine if the destination folder is connected to the server machine (which is not the case now).
    >
    Look into multipart MIME requests, Jakarta Commons File Upload, and things like that to actually upload files to a server instead of insisting on reading them directly from the client's filesystem in your servlet and wondering why that doesn't work if the servlet container is running on a different computer from the client.I AM using Jakarta Commons File Upload. The problem is when I try to access the destination folder(which is in client machine), it can't find as it is searching for the corresponding folder in the server.
    >
    Unless and until you do that, you're wasting our time and your own.I thought someone could help me i giving me some pointers which I missed. Thanks again!!
    Edited by: AnishThomas on Mar 14, 2008 8:13 AM

  • How to print html file on client system without viewing data on client syst

    I want to print html data from database.
    i am not able to print it using java code,
    javascript can do that.
    but in javascript window is opened on client browser.
    but i dont want to open that
    var disp_setting="toolbar=no,location=no,directories=no,menubar=no,";
           disp_setting+="scrollbars=no,width=0,height=0";
         var docprint = window.open("","",disp_setting);
         //docprint = new PopUpWindow() ;
         docprint.document.write('<%= mm %>');
         docprint.document.close();
            docprint.focus();
         docprint.document = null; mm contents the data to be printed. it prints well but window is shown
    in mm there is <BODY self.print() > so it prints on printer but i am viewing window i donot want to view window....
    and print Dialog box also.. I want to by pass this both.
    please send me code or any help regarding that.
    ....

    1. Post a javascript question on a javascript forum please.
    2. Don't think you can bypass without some plugin/setting on the client browser.

  • How to download an excel file in client place

    How to download an excel file in client place?
    Iam using sun apps server..
    i need the code urgently..anyone help me pls,..

    just build a link to that file location on the server and send it back to the client
    MeTitus

  • How to create a file in the server?

    Hi,
    I'm making a webservice that has to generate a XML file, sign it using another webservice and return this XML. The problem is that i don't know how to create the file in the server throught webservice.
    I use this code in the webservice to generate the XML and after I return the XML to client in a byte[]
         static void outputDocumentToFile(Document myDocument, String path) {
            //setup this like outputDocument
              try {
                   // XMLOutputter outputter = new XMLOutputter("  ", true);
                   XMLOutputter outputter = new XMLOutputter();
                   //output to a file
                   FileWriter writer = new FileWriter(path);
                   outputter.output(myDocument, writer);
                   writer.close();
              } catch(java.io.IOException e) {
                   e.printStackTrace();
        }But the file is generated in the client-side, how can I generate the file in the server-side?
    Thanks very much.

    Well the File object doesn't create a file it's simply an abstract representation of file and directory pathnames.
    You can try something like this:
    <%
    try
    // get the path to the web server root
    // I read somewhere not to use 'getRealPath' for some reason which I
    // can't seem to remember :S Hopefull someone can enlighten us :)
    String path = application.getRealPath("/project/jsp/demo.txt");
    File file = new File(path);
    PrintWriter writer = new PrintWriter(new BufferedWriter(new FileWriter(file)));
    writer.println("Hello World!");
    writer.close();
    catch (Exception e)
    System.err.println(e.getMessage());
    %>
    Hope this helps :)

  • FRM-92101 when creating excel file through webutil

    I am getting forms error FRM-92101 error when loading a large amount of records into an excel file using webutil
    FRM-92101
    A Network Error has occurred
    The forms client has attempted to reconnect to the server 1 time(s) without success
    I can successfully create the excel file without the the FRM-92101 when loading only 100 out of 2,000 records from the datablock.
    But if I try to load 1,000 out of the 2,000 records then in the middle of the loading process I get the FRM-92101 error.
    What is causing this error? A timeout issue with forms? How much the excel file can actually handle? Could it be an security issue on the network?
    What can be done to remedy the problem? Just save data little bits at a time?
    Thanks,
    Michelle

    I was running the form from my DS and when I put the form on the application server there were no FRM-92101 errors.
    I'm not sure why running the form from my DS caused this error and running the form from the application server didn't?
    Thanks,
    Michelle

  • Automatically schedule FR or IR reports to create Excel files???

    Hello,
    My client asked me to 1) create reports against Essbase cubes, 2) automate the update of the reports to Excel files and 3) email the results to various people. In the first phase of this project I was able to do some of this as follows:
    1) Created FR reports.
    2) Scheduled the update of the FR reports to PDF files using the scheduler in Hyperion Workspace. NOTE: I created PDF files because that is the only thing that the scheduler can automatically produce from FR reports.
    3) Created an Excel VBA application that emails the PDF files to a variable list of recipients (each report goes to a different list of people).
    Now we are entering the second phase of this project and the client is asking to have the reports created in Excel files instead of PDF.
    ***** Questions *****
    1) Can an IR report be scheduled using the Hyperion Scheduler in Hyperion Workspace to create Excel files?
    2) Is there a utility (either Hyperion or other) that can convert PDF files to Excel files with the exact formatting of the original PDF?
    Thank you,
    Bill H

    Thank you for your reply. After your reply I looked in the Hyperion Workspace User Guide and found how to schedule an IR report to create an Excel file. I think the next thing I am trying to determine is how to do "bursting" in IR. I currently have an FR report that gets data from Essbase. I have scheduled this in Workspace to run for all children of a member (or a different example would be all zero level decendants of a member). The Workspace scheduler allows me to create a file for each member and to add the member name to each filename so that they are different. Can I do the same type of thing with IR?
    Thank you,
    Bill H

  • How to create txt file in utf-8?

    Hi,
    if i create a txt file using vb in fdm, it is created with the ansi encoding. Is there any option how to create this file in utf-8?
    Thx

    Forms6i uses Oracle 8.0.6 client libraries. MetaLink Note 207303.1 lists supported client/server configurations, and the last database version supported with those libraries is Oracle 9.2. The only exception is made for e-Business Suite (Oracle Applications). Therefore, you configuration is not supported.
    Anyway, Oracle 8.0.6 does not support AL32UTF8 well. You should select UTF8 as the database character set (not national character set!). You need to select a check box on DBCA interface (possibly unavailable in fast/default installation path) which allows you to see non-recommended character sets.
    -- Sergiusz

  • How to Create a SAP R/3 system in system configuration

    Hi,
    i am new to EP Any body tell me how to Create a SAP R/3 system in system configuration.Thanks in advance.
    Thanks
    kiran.B

    Hi Kiran,
    To create SAP R3 System follows this steps :
    in system landscape
    (1)create new system
    (2)select SAP system using dedicated application server
    (3)give system name and id
    (4)finish
    (5)open system and set following properties
         Connector
         - App. Host              : r3 server name
         - Gateway Host        :
         - SAP client             :
         - SAP System Name:
         - SAP System No.    :
         - Server Port             : 3200 (Default)
         - System Type
         -  give system Alias
         User Management
         - Logon Method
                      UIDPW

  • Problem to create Excel file

    Hi,
    I'm to create Excel file by C# codes and have got this
    Error 1 Assembly 'Microsoft.Office.Interop.Excel, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c' uses 'office, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c' which has a higher version than referenced assembly 'office, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c'
    Error 2 Assembly 'Microsoft.Office.Interop.Excel, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c' uses 'Microsoft.Vbe.Interop, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c' which has a higher version than referenced assembly 'Microsoft.Vbe.Interop, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c'
    using these codes
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using System.Threading.Tasks;
    using System.IO;
    using System.Text.RegularExpressions;
    using System.Globalization;
    using System.Collections;
    using System.Diagnostics;
    using System.Drawing;
    using Microsoft.Office.Interop;
    using Excel = Microsoft.Office.Interop.Excel;
    namespace ns1
    class Program
    static void Main(string[] args)
    string orp_path = "//ABC";
    bool allowappend = true;
    string test = "test";
    Excel.Application app = null;
    Excel.Workbook workbook = null;
    Excel.Worksheet worksheet = null;
    Excel.Range workSheet_range = null;
    object misValue = System.Reflection.Missing.Value;
    Excel.Application xlApp = new
    Microsoft.Office.Interop.Excel.Application();
    workbook = xlApp.Workbooks.Add(misValue);
    workbook = xlApp.Workbooks.Add(misValue);
    worksheet = (Excel.Worksheet)workbook.Worksheets.get_Item(1);
    worksheet.Cells[1, 1] = "Run Date";
    workbook.SaveAs("c:\\" + test + ".xls", Excel.XlFileFormat.xlOpenXMLTemplate, misValue, misValue, misValue, misValue, Excel.XlSaveAsAccessMode.xlExclusive, misValue, misValue, misValue, misValue, misValue);
    workbook.Close(true, misValue, misValue);
    xlApp.Quit();
    releaseObject(worksheet);
    releaseObject(workbook);
    releaseObject(xlApp); ...
    on VS 2013. Any advice?
    Many Thanks & Best Regards, Hua Min

    Hey,
    Not sure what the problem is, I got the code working.
    One thing you're doing wrong though: Excel.XlFileFormat.xlOpenXMLTemplate supposes you're using the file extension ".xlsx" (Open XML format) and not ".xls" (Microsoft Excel 97-2003).
    So you should start by changing either the extension to xlsx or the XlFileFormat to
    xlExcel8.
    For further reference take a look
    here

  • How to create xpi file for my own extension?

    I have created my own extension and directly added profile extension folder in my system.its working fine. but while installing extension using .xpi file its produce error "Install script not found
    -204".Please explian me how to create .xpi file for my extension folder.
    I hope you can help this issues.
    Thanks in advance.
    Regards
    vasanthi

    See this:
    https://developer.mozilla.org/en/Building_an_Extension

  • How to create logical file name

    Could some one tell me how to create logical file names in BW , and when to use the transaction SF01.
    Thanks

    The following describes the procedure for creating a cross-client definition using the transaction FILE.
    You create the client-specific definition in the same way using transaction SF01.
    1.Call transaction FILE for cross-client file names.
    2.Double click the dialog structure Logical File Name Definition, Cross-Client.
    You access the screen Change View "Logical File Name Definition, Cross-Client": Overview

  • ORA-06508 cannot create excel file

    Hi,
    I have forms 6i and windows 7. We have few forms which should create excel files but all of them fail with ORA-06508 and it happens only on my PC. Other colleagues don't have any problem with it. Forms path on my PC is the same as ones on other PC's.
    Also weird, when I run problematic forms through debugger, they work correctly and create excel files.
    How to solve this?
    Tnx in advance,
    Nati

    Nati,
    Recompiling libraries is not an option because of dependencies on too many forms. The number of Forms in your application and their dependencies is irrelevant if you follow one simple rule: Always compile PL/SQL Libraries first; compile Menu Modules second and lastly, compile your Forms. This will eliminate the dependency issues.
    Anyway, mass recompiling is not allowed because of company rules. I disagree with this rule, but I don't work for your company! ;) Perhaps it is time for your company to re-evaluate this rule. :)
    I tried with replacing ";" with ";" in particular form and the result was non-oracle exception 304500 which unfortunately doesn't say anything detailed. If this produced an error, I recommend you close all Forms related applications; re-open Forms builder and try again. This method should never produce an error.
    I have forms 6i and windows 7.Forms 6i is not supported with Windows 7. More importantly, they are not compatible with each other. Forms 6i was designed to run on Windows 95/98. The differences between the Windows versions is tremendous. If you are unable to upgrade your Forms version, then at the very least, I recommend you run your application in Windows XP mode. This is not just setting the "Compatibility" to Windows XP. Take a look at Windows XP Mode - Windows 7 features, Install and Use Windows XP Mode in Windows 7 and Download Windows XP Mode.
    Running Forms 6i on Windows 7 is like mixing Pickles with Ice Cream. Somethings are just not meant to go together. :)
    Craig...

Maybe you are looking for

  • Can i connect an external signal generator to the NI7344 to...

    Can i connect an external signal generator to the NI7344 to use its PID characteristics to precisely control the output I am using the flex motion board (NI7344) to control the force output of a linear motor. Using contouring and buffer operations i

  • Desktop 6.2.2 will not save data

    Since I upgraded to 6.2.2 from 4.1.4 my Desktop will only save old data, like items more than 2 years old. On restarting the computer, it wipes out anything new. But not always... I've tried reinstalling it several times. It seems like it starts to s

  • Po report with purchase requistion

    Hi experts, how to get list of purchase orders which are not created through purchase requisition. through me5a i will get requisiton tracking with purchase order. i need a report which shows purchase order number with purchase requisiton no. i check

  • COPA document not generated though after billing and accounting generations

    I have an issue with one instant. For some reason COPA document is not generated even though billing and accounting document were created. Found no errors in simulation using KE4ST. The billing item details has all the PA segment characteristics. COP

  • Speaker Not Working

    i have a macbook 2009 with osx mavericks (10.9.4). so i was watching youtube, then suddenly my macbook freezes and i can't do nothing about it. so i force shutdown and turn it on again. when it's on, my speaker is not working and when i check the sou