Saving excel file as .csv via OLE program

Hi all,
in my abap OLE program i'd like to save an excel file as .csv file with ";" separator according to the frontend settings. Unfortunately the file is saved with "," separator (and not ";").
Here is the code:
<<...
     call method of e_newappl 'SAVEAS'
     exporting
       #1 = path
       #2 = '23' ....>>
I also tried 6, 22, 24 as #2 parameter values, with the same result. Running the program in differents workstations (all with ";" separator in the general settings) sometimes i get a file with ";" and sometimes with ",".
Is there a way to always get the .csv  file with ";"? Or at least to check what separator will be used?
Thanks for replies.

hi,
please check this similar thread for the answer
Sample code to download data to .CSV file using OLE method
thanks

Similar Messages

  • Inputting an excel file to the java servlet program

    Hi,
    How can I input an excel file into the java servlet program? I am using POI HSSF programming to read the content of that excel file.I have created a form that will accept the path from the user and in the servlet program, I have called a post method to retrieve the path of the file. I am getting the path of the file as a string.Then I have to access the file to read the data. But it is not working. What should I do?.Please help me.
    I have created an html file to create a form that will ask the path of the file to be loaded into the servlet program.Please give me a solution,thanks in advance. The servlet program that receives the file is shown below. It just only take the name of the file and prints if that is ok.
    <html>
    <body bgcolor="green">
    <center>
    <form method="post"  action="http://localhost:8080/examples/servlet/Ron1">
    <table>
    <tr>
    <td><B>ENTER THE PATH OF THE FILE</td>
    <td><input type=file name="path"></td>
    </tr>
    </table>
    <input type=submit value= "submit" >
    </form>
    </body>
    </html>
    import java.io.*;
    import javax.servlet.*;
    import java.lang.*;
    import javax.servlet.http.*;
    import java.sql.*;
    import java.text.*;
    import java.util.*;
    import com.oreilly.servlet.MultipartRequest;
    import org.apache.poi.hssf.usermodel.*;
    public class Ron1 extends HttpServlet
       public void doPost(HttpServletRequest request, HttpServletResponse response)   throws IOException, ServletException
            response.setContentType("text/html");
            PrintWriter out = response.getWriter();
            String u = request.getParameter("FileToUpload");
            out.println("The Path is "+u);
            System.out.println("The path is "+u);
            MultipartRequest multi = new MultipartRequest(request,u,10 * 1024 * 1024);
            System.out.println("path is "+u);
            Enumeration files = multi.getFileNames();
            File fUploadedFile = null;
            String sFileName = "";
            out.println("path is "+u);
            while(files.hasMoreElements())
                            String name = (String)files.nextElement();
                            out.println("file is "+name);
                            sFileName = multi.getFilesystemName(name);
                            String type = multi.getContentType(name);
                            fUploadedFile = multi.getFile(name);
                    FileInputStream fis= new FileInputStream(fUploadedFile);
                   HSSFWorkbook wb=new HSSFWorkbook(fis);
                    System.out.println("The path is "+u);
                    out.println("File has identified successfully\n");
                    out.close();
       }

    Hi,
    Can you try to use classes from java.net package (URL, URLConnection) to pass the contents of excel file to servlet?
    HTH
    Vishal

  • How to save an excel file as CSV with semi-colon as data separator?

    We are creating a flat data file to load the flat file data to our BW system with Excel.  When we save the file, there are three kinds of CSV types for selecting from the "Save as type" list box:
    CSV (Comma delimited)
    CSV (Macintosh)
    CSV (MS-DOS)
    There is no CSV (semi colon delimited) type.  If we pick CSV (Comma delimted) as the type, then when clicking the "Preview ..." picture icon under the "DataSource/Trans. Structure" tab of the InfoSource for this flat file (with the CSV radio button checked the Data separator default is ";"), the File Upload Preview window shows the data is messed up that some columns of the excel flat file are combined into one column.
    Since the save type we picked is "CSV (Comma delimited)", then we try to change the default Data separator from ";" to "," in the preview selection screen, but still not helpful!
    How to resolve the above problem?
    Thanks

    Hi Kevin,
    This "," is defined in your windows setting. If you want to have ";" as separator then go to control Panel, select Regional Options, go to Numbers Tab and define the List separator as ";". After that when you will save your excel file as CSV(MS-DOS) it will have ";" as separator. This will make sure that the amounts are not broken in to two different fields while loading.
    Else if you keep "," as separator then you can also go into the Excel and define all number fields as Number without thousand separator.
    Let me know if you have any doubts in this.
    Regards,
    Rohit

  • Saving excel file attachment on phone

    I received and excel file via email on my phone and would like to save it for later to use with the office plus program. I can open the file from my phone but do not know how to save it. Can anyone help.

    Prakash,
              I have followed your weblog and set the content dispostion.
    HttpServletResponse res = request.getServletResponse(true);
                   try {
                        res.setContentType("application/vnd.ms-excel");
                        res.setHeader("Content-disposition", "inline; filename=report.xls");
                        wb.write(res.getOutputStream());
                   } catch (Exception e) {
                        e.printStackTrace();
    When I test this on my pc, I get file download window and I can choose 'open' or'save'. I also have tested this on some of my collegues PCs successfully. But the some of the end users are not getting this window.
    when the same is file is downloaded by running an asp page the enire MSExcel application with standard tool bar and menus(file edit etc..) is showing up.
    Why is it not poosible to get the same result using HSSF api?

  • How to save excel file as *.csv

    Hi.
    I must upload excel file and next save as *.csv.
    How can i do it?

    Hi,
    USe the code given in the link
    http://www.sapdevelopment.co.uk/file/file_upexcel.htm
    Cheers
    VJ

  • Saving Excel Files to CD-RW

    For some years now I've been able to insert a CD-RW disc, double click on an Excel file stored there, open the file, edit the file, then simply resave the file under the same file name back onto the CD-RW disc.
    Seemingly, suddenly I am no longer able to do that.  Now when I double click on the Excel file, it opens as "Read Only".  After I make my edits, the system wants me to save under a new file name because the file is "Read Only".  When I do that, the system now "saves" the file to a temporary burn folder rather than writing the file to the disc.  I then burn the file to the disc and a new file is added under the new name.
    I could probably handle the extra step of burning the file to the CD-RW everytime but I simply want to overwrite the previous file, not fill up the disc with new files everytime.
    How do I get back to inserting the disc, opening the file, editing the file and saving the file to the disc, then being able to repeat all of that but rewriting the file not creating a new one everytime?  I'm sure that I am missing something fundamental in how writing to CD-RWs works.
    Thank you.

    Why not use a USB thumb drive, and avoid the hassles?
    I am a volunteer. I am not an HP employee.
    To say THANK YOU, press the "thumbs up symbol" to render a KUDO. Please click Accept as Solution, if your problem is solved. You can render both Solution and KUDO.
    The Law of Effect states that positive reinforcement increases the probability of a behavior being repeated. (B.F.Skinner). You toss me KUDO and/or Solution, and I perform better.
    (2) HP DV7t i7 3160QM 2.3Ghz 8GB
    HP m9200t E8400,Win7 Pro 32 bit. 4GB RAM, ASUS 550Ti 2GB, Rosewill 630W. 1T HD SATA 3Gb/s
    Custom Asus P8P67, I7-2600k, 16GB RAM, WIN7 Pro 64bit, EVGA GTX660 2GB, 750W OCZ, 1T HD SATA 6Gb/s
    Custom Asus P8Z77, I7-3770k, 16GB RAM, WIN7 Pro 64bit, EVGA GTX670 2GB, 750W OCZ, 1T HD SATA 6Gb/s
    Both Customs use Rosewill Blackhawk case.
    Printer -- HP OfficeJet Pro 8600 Plus

  • Retrieve online file as CSV via HTTPS using PL/SQL procedure

    Hi all,
    Situation:
    Server A (not ORACLE)_: accesed via URL, generates dynamically a CSV file and returns to the requestor.
    Server B (ORACLE)_: which runs the PL/SQL script. It is the requestor. Read the CSV and store it within ORACLE.
    (1) I want to connect from Server B (ORACLE) to an external URL via HTTPS which generates dynamically the CSV file. Subdomain.domain it is the Server A which contains this CSV file.
    https://dubdomain.domain/csv_generator.php?query=q1
    (2) This file is downloaded to the Server B (ORACLE). A PL/SQL script executed in this machine do the task.
    (3) After that, I load this CSV to an ORACLE table which a common CSV PL/SQL parser.
    Doubts:
    Is it possible to retrieve an online file (a CSV) dynamically created and hosted in a third party server (Not ORACLE) via HTTPS using a PL/SQL procedure executed in a ORACLE server? If the answer is yes, what technology could I use? Any ideas?
    Thanks in advance,
    Yago

    An CSV example in {message:id=10158148}.
    For https, two actions are needed in addition.
    Firstly, the certificate of the https web server needs to be loaded in an Oracle Wallet on your database server. The wallet will have a specific directory location on the server, and will be protected by a password.
    Secondly, the PL/SQL procedure making web call, needs to open the wallet (using <i>UTL_HTTP.set_wallet</i>) using the location and password. Example of that in {message:id=10820182}.

  • How to Read data from excel file without converting a excel file into .csv or any other format

    Hello,
    Can somebody suggest me how to read from an excel file (consisting of 10 work sheets) to an array?
    Thanks,
    She

    You have to be careful when using the spreadsheet-files vi's.  They are located in the Functions Palette under File IO, you will find "Write To / Read From Spreadsheet File.vi"s. 
    Here is what the Context Help says about the vi function:
    "Reads a specified number of lines or rows from a numeric text file beginning at a specified character offset and converts the data to a 2D, single-precision array of numbers. You optionally can transpose the array. The VI opens the file before reading from it and closes it afterwards. You can use this VI to read a spreadsheet file saved in text format. This VI calls the Spreadsheet String to Array function to convert the data. "
    This is quick & easy when the spreadsheet is all the same format.  You can set the format to string as well.  HOWEVER...  you do have to convert the Excel spreadsheet to text before using it.
    I haven't experimented with the Active-X, but it may look as the way to go if you have combination text / numeric values in the spreadsheet.
    If you did convert it to text, then you can use array functions as well and treating the file as an array of strings (see very brief example attached).  The example is to illustrate a point only  
    JLV
    Attachments:
    starting point for spreadsheet.vi ‏28 KB

  • Saving Excel file as JPEG or BMP image

    Hi,
    i need a solution how to save an Excel file as jpg or bmp format.Please help me out in this. it is very urgent. i am passing an Excel file as input and it should be converted into a image.
    Thanks,
    chandras.

    Hi,
    I tried in google. i used POI. But i didnot get.Your Google skills aren't very good, then. I typed "convert excel to bmp" into Google and got a whole lot of programs and services that say they can do it. Probably the idea that it's urgent is preventing your brain from working properly. Try to not panic.

  • App open Excel file using CSV format

    Actually I would like to find app open Excel file and add some date and save it again under CSV format

    Numbers will do that (using the export function). I'm sure many other Excel compatible apps will as well, but you will need to read the app store descriptions to verify. (I can verify that Quick Office does NOT).

  • Is it possibke to extract import data from excel file not csv type

    I am getting training from somebody, who is telling me the excel file has to be type csv only to extract and import the excel data for creating infoobjects, is that true.
    Please kindly provide steps, if any one has steps to extract the excel data while creating info object.
    I am going thru an excersise for creating info objects, but while brining the excel csv file data to info objects do i again need to create each field column and its attributes etc.
    Thank you all for the helpful info.

    Hi
    If you want to load data from excel to BW(Info Objects or data source), then file should be in excel format. to import the data system directly import it into excel sheet(normal one)
    to load the data you should have all values and attributes in your excel sheet which you have created in BW system.
    http://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/4096b8fc-6be7-2a10-618e-b02a5e5e798f
    http://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/a0a556c6-f9e6-2a10-b58d-c68e42c26370
    check the above two, those are very useful
    Regards,
    Venkatesh

  • Saving excel file

    Hi,
        I am able to export all table data into excel file with the help of tutorial "Exporting Context Data into
    Excel Using the Web Dynpro Binary Cache".
         But instead of the process described in the tutorial i want to save the file directly and send it as attachment.
         If anybody knows it please help me its urgent.
            Thanks and regards
            Pankaj.k

    Hi,
    You can do something like this:
    From the navigator view in NWDS, create a new file, say "TableData.csv" under src/mimes/Components/<your component>/TableData.csv.
    Say your context looks like this:
    -Root
    --Texts(value node, datasource for your table)
    ---Msg(value attribute, bound to 1st column of table)
    ---Msg2(value attribute, bound to 2nd column of table)
    In the event handler for send button, use a code like this:
    String path = null;
    try {
    path = WDURLGenerator.getResourcePath(
    wdComponentAPI.getDeployableObjectPart(),
    "TableData.csv");
    } catch (WDAliasResolvingException e2) {
    // TODO Auto-generated catch block
    e2.printStackTrace();
    try {
    FileWriter f = new FileWriter(path);
    BufferedWriter b = new BufferedWriter(f);
    IWDNode tableNode = wdContext.nodeTexts();
    for(int i = 0; i < tableNode.size(); i++){
    IWDNodeElement currElem = tableNode.getElementAt(i);
    b.write(currElem.getAttributeValue("Msg").toString());
    b.write(",");
    b.write(currElem.getAttributeValue("Msg2").toString());
    b.write(",");
    b.newLine();     
    b.close();
    } catch (IOException e) {
    // TODO Auto-generated catch block
    wdComponentAPI.getMessageManager().reportException(e.getMessage(),true);
    See your other thread.
    Regards,
    Satyajit.

  • Error while saving Excel File

    I have installed Microsoft Home & Business 2013, when i tried to save the excel file i am getting a message If you want to save documents with this file type, disable the registry policy setting from these path File---> Options--->Trust Center
    and then click Trust Center Settings----->File block settings. But in Truest center settings their is no FILE BLOCK SETTINGS. 
    I donot have MSDN ID Or 7 digit partner ID.
    so Pls guide me...
    Megha

    Hello,
    The Forums Issues (not product support) forum is to report issues with the online forums application. This is not a support forum.
    You should ask in the Microsoft Office Community Forums.
    Karl
    When you see answers and helpful posts, please click Vote As Helpful, Propose As Answer, and/or Mark As Answer.
    My Blog: Unlock PowerShell
    My Book:
    Windows PowerShell 2.0 Bible
    My E-mail: -join ('6F6C646B61726C406F75746C6F6F6B2E636F6D'-split'(?<=\G.{2})'|%{if($_){[char][int]"0x$_"}})

  • Downloading Excel File in CSV Format

    Hi All,
    How can I Download a file in .CSV Format?
    I am using the below shown code.
    CALL FUNCTION 'GUI_DOWNLOAD'
      EXPORTING
      BIN_FILESIZE                    =
        FILENAME                        = 'C:\Documents and Settings\sandeepp3\Desktop\sample.csv'
        FILETYPE                        = 'DAT'
      APPEND                          = ' '
        WRITE_FIELD_SEPARATOR           = ','
      HEADER                          = '00'
      TRUNC_TRAILING_BLANKS           = ' '
      WRITE_LF                        = 'X'
      COL_SELECT                      = ' '
      COL_SELECT_MASK                 = ' '
      DAT_MODE                        = ' '
      CONFIRM_OVERWRITE               = ' '
      NO_AUTH_CHECK                   = ' '
      CODEPAGE                        = ' '
      IGNORE_CERR                     = ABAP_TRUE
      REPLACEMENT                     = '#'
      WRITE_BOM                       = ' '
      TRUNC_TRAILING_BLANKS_EOL       = 'X'
      WK1_N_FORMAT                    = ' '
      WK1_N_SIZE                      = ' '
      WK1_T_FORMAT                    = ' '
      WK1_T_SIZE                      = ' '
      WRITE_LF_AFTER_LAST_LINE        = ABAP_TRUE
      SHOW_TRANSFER_STATUS            = ABAP_TRUE
    IMPORTING
      FILELENGTH                      =
      TABLES
        DATA_TAB                        = ITAB
        FIELDNAMES                      = HTAB
    EXCEPTIONS
      FILE_WRITE_ERROR                = 1
      NO_BATCH                        = 2
      GUI_REFUSE_FILETRANSFER         = 3
      INVALID_TYPE                    = 4
      NO_AUTHORITY                    = 5
      UNKNOWN_ERROR                   = 6
      HEADER_NOT_ALLOWED              = 7
      SEPARATOR_NOT_ALLOWED           = 8
      FILESIZE_NOT_ALLOWED            = 9
      HEADER_TOO_LONG                 = 10
      DP_ERROR_CREATE                 = 11
      DP_ERROR_SEND                   = 12
      DP_ERROR_WRITE                  = 13
      UNKNOWN_DP_ERROR                = 14
      ACCESS_DENIED                   = 15
      DP_OUT_OF_MEMORY                = 16
      DISK_FULL                       = 17
      DP_TIMEOUT                      = 18
      FILE_NOT_FOUND                  = 19
      DATAPROVIDER_EXCEPTION          = 20
      CONTROL_FLUSH_ERROR             = 21
      OTHERS                          = 22
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    I am getting the field separator as Tab(SPACE).
    Please Advise

    Hi Anil,
    Try this way.
    REPORT ztest_notepad.
    "Declarations
    TYPE-POOLS :truxs.
    DATA : it_download TYPE truxs_t_text_data.
    DATA: BEGIN OF it_data OCCURS 0,
            arbgb TYPE t100-arbgb,
            msgnr TYPE t100-msgnr,
            text TYPE t100-text,
          END OF it_data.
    START-OF-SELECTION.
      "Select Data
      SELECT * FROM t100
      INTO CORRESPONDING FIELDS OF TABLE it_data UP TO 200 ROWS   WHERE sprsl = sy-langu.
      "Convert SAP to CSV format
      CALL FUNCTION 'SAP_CONVERT_TO_CSV_FORMAT'
        EXPORTING
          i_field_seperator    = ';'
        TABLES
          i_tab_sap_data       = it_data
        CHANGING
          i_tab_converted_data = it_download
        EXCEPTIONS
          conversion_failed    = 1
          OTHERS               = 2.
      IF sy-subrc = 0.
        "Download data using GUI_DOWNLOAD
        CALL FUNCTION 'GUI_DOWNLOAD'
          EXPORTING
            filename = 'C:\test.txt'
            filetype = 'ASC'
          TABLES
            data_tab = it_download.
      ENDIF.
    Thanks
    venkat.O

  • Problem saving Excel files sent in mail

    This problem is since I upgraded to Maverick.
    I receive an Excel file ( file.xls ) in Mail as an attachment and when I try to save there is an existing file with the same name it then ask if I want to replace it and I answer Yes. The problem is is does not replace the file and I dont get any error messages. I must delete the old version of the file first then save the new version. I dont know if it is Mail or Excel that has a problem with Maverick. Doe anybody else have this problem?

    I am experiencing exactly the same problem, but with text files. It seems that the "replace" doesn't work, but with no explaination or warning. Extrememly frustrating. (Mail 7.0, Mavericks 10.9)

Maybe you are looking for

  • Not able to fetch the explain plan

    whenever i fire this query, its giving table does not exits SQL> EXPLAIN PLAN for SELECT S_CONTACT.ROW_ID, 2 3 S_CONTACT.MODIFICATION_NUM, 4 S_CONTACT.LAST_UPD 5 FROM 6 S_CONTACT, 7 S_CONTACT_FNX, 8 S_ETL_I_IMG_118 IMG 9 WHERE 10 ( 11 IMG.ROW_ID = S_

  • [HTML DB] How to use the existing database table?

    [HTML DB] How to use the existing database table? I installed Oracle 10g database in Computer A(Windows 2000), and I already create all the tables with data and the data size is about 300MB. In Computer B(Windows 2000), I installed HTML DB 1.6. How c

  • Credit receipt exceeds Maximum amount allowed

    Hello, We were recently requested to update one of our expense type's "Default/Max. value", also we were requested to have the "Amount type" set to "Error message for exceeding maximum".  We have now come across a problem where credit receipts that a

  • System not coming up for PSS in AC 10.0

    I started configuring AC 10.0 and added connectors using SPRO but when i go to nwbc to reset my password it is not bringing up any systems list. Should i be checking something to bring in the list of systems. Thanks Uday

  • Photoshop CS6 Release Build Date Implies Beta Preferences Valid

    Interestingly, it looks like the released code is closely related to the beta code...  Build date and time of the released files are March 15, 2012 at 3:22 am (someone was burning the midnight oil). I guess that says they didn't feel anything was too