Read Write Data into a MS Word document

The requirement I am fullfilling directly specifies the need to write data into a Microsoft Word Document and if Necessary, Read Back data from a Microsoft Word Document. The data will be simple text but as time goes on I anticipate the systems engineers may expand the requirement. I want to cross one bridge at a time so I am just concentrating on the text issue. I must do it from within a stand-alone application. Not through a server, not through ASP, not through a browser, just a stand alone application. It appears from my own investigation of the JAVA API that this is not possible. Regrettably, I am only a day or so away from switching to C# or VB to get this job done. My first question is
1. Can Java Do this?
2. If not, does Sun Microsystems have any plans to add this capabiliy?
3. Can we make recommendations to Sun to add this capability to JAVA?

1. Can Java Do this?Java can do anything but there is no built-in ability to do just that.
2. If not, does Sun Microsystems have any plans to add
this capabiliy?
3. Can we make recommendations to Sun to add this
capability to JAVA?Very doubtful! MS Office document formats are not completely open to the public - and they are weird! Supporting this capability would probably require an agreement with Microsoft and it would mean you had to change the API for every time Microsoft chooses to change the document formats.
But there are some open source tools that claim to be rather good at reading and writing MS Office files. Take a look at this one:
http://jakarta.apache.org/poi/index.html

Similar Messages

  • How to use active X controls to read/write protect an excel or word document created by created by Save Report to File VI

    Hi all,
    I'm trying to creat a word and excel documents using Save Report to File VI. When wiring a password to this last VI, the document created are only protected against writing but not reading. How can I use active X controls to password protect these documents against reading?
    Thanks a bunch!
    O

    There is no predefined functionality available in LabVIEW. So you have to implement this on your own.
    It seems to me that you own the Office Report Generation Toolkit. You can use the Excel Get ActiveX References.vi from the Excel Specific >> Advanced palette to get access to the "generic" ActiveX Excel references. Starting from this point, you can use property and invoke nodes to get to the setting you are going to modify.
    Please refer to this link for information on Excel password protection. I have not searched for the object giving you access to those settings though....
    hope this helps,
    Norbert
    CEO: What exactly is stopping us from doing this?
    Expert: Geometry
    Marketing Manager: Just ignore it.

  • How can I convert a pdf document written in the Cyrillic (Russian) script into a MS Word document in the Cyrillic script?

    I wish to convert a pdf document using a very small font from Cyrillic script into an MS Word document likewise using Cyrillic script. Then I could zoom up the size of the pdf document's script. Is there any way  this can be done?
    Julyan Watts, Hungary

    Why can't you just zoom in Adobe Reader?

  • Unable to write data into excel file when it's close

    Hi,
    I'm facing this problem and it's a bit weird. I'm using the following method to insert data into excel file. But when excel file is close, it unable to write data into the excel sheet. But it was able to write the data into the excel sheet if i open the excel file when running the program.
    Can anyone please tell me what's wrong to the code?
    public int updateLog(String sheet, String no, String cpId, String CatId, String rbtCode, String rbt, String rbtName, String artistName, String price, String rbtFileName, String songId, String msg){
            int result = -1;
            try{
                SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss",Locale.ENGLISH);
                String actionDate = formatter.format(new Date());
                rbtName = rbtName.replaceAll("'", "''");
                artistName = artistName.replaceAll("'", "");
                String sql = "insert into [Sheet3$] (Code, CpID, CategoryID, RBTCode, RBT, RBTName, ArtistName, Price, RBTFileName, SongID, UploadStatus, FileUploadedDateTime) ";
                sql = sql + " values ('" + no + "', '" + cpId + "', '" + CatId + "', '" + rbtCode + "', '" + rbt + "', '" + rbtName + "', '" + artistName + "', '" + price + "', '" + rbtFileName + "', '" + songId + "', '" + msg + "', '" + actionDate + "')";
                System.out.println(sql);
                log.writeLog(sql);
                result = stmnt.executeUpdate(sql);
            } catch(Exception e){
                e.printStackTrace();
                log.printStackTrace(e);
            return result;
        public int openConnection(){
            int result = -1;
            try{
                Class.forName(dbDriver);
                c = DriverManager.getConnection(conStr + excelFilePath+";ReadOnly=0;");
                stmnt = c.createStatement();
            } catch(Exception e){
                e.printStackTrace();
                log.printStackTrace(e);
                return -1;
            return 1;
        }Thanks

    HI,
    i hv a doubt regarding reading / opening of a
    password protected Excel file using jxl( java ) .
    How to read / open a password protected Excel file
    thro Java (jxl ) program .plz let me know some
    example also .
    Regards,
    Ramesh P
    845935822cross posting !! answered here
    http://forum.java.sun.com/thread.jspa?threadID=710466&messageID=9507085#9507085

  • I want to write data into eeprom(93LC86) in parallel port using labview?

    I want to write data into eeprom(93LC86) in parallel port using labview? Also I want to read data from EEprom.

    Hi Mr. Mz,
    after having a look to 93LC86-Datasheet I do not see a problem. The self-timing programming cycle of this Chip avoids timing problems; the rest is only logical stuff.
    If you need more general info, how to use the parallel port, I recommend: http://[email protected]/ or
    in case you need an example of SPI-Interface in LabVIEW with paraport - then write to: [email protected]
    You are welcome
    regards
    wha

  • Is it possible to read/write data from Salesforce using web service hub in Informatica?

    Anyone from Informatica can asnwer this question please

    Is it possible to read/write data from Salesforce using web service hub in Informatica? Not asking about PowerExchange for Salesforce or Informatica Cloud. Just using web service can we load data into Salesforce? Thanks ahead.

  • How to activate another worksheet in excel file and write data into it

    Hi,
    I am writing an automation program to collect test data and write the data to an excel file.
    The excel file has several worksheets and now I can only write data to one sheet. Can anyone please let me know how to activate another worksheet and write data into it? Thank you very much.

    You can do a search in the Example Finder for more Excel VIs.
    They will give you a clearer idea of how to go about doing things in the way you need.
    - Partha
    LabVIEW - Wires that catch bugs!

  • Urgent!!! Need help in file read/write data to a serial port

    Hi,
    I really need someone's help in order for me to complete my project. I have attached a vi which I have taken from an example and integrate to my project. In the vi, I have managed to get the encoder counts using Ni 9411. I need to read/write that data from ni9411 to ni9870 without using any serial port as they are connected to a NI 9104 chasis. May I know whether I am correct in writing the data to my ni9870 port using the vi I have attached? Does anyone know how i can convert the number of counts to a 8-bit data/byte so that I can send the data through the RS232 port? I really need someone's help as I need to finished in 2 weeks time.
    I have also attached an vi on controlling the epos2 controller using instrument driver. Does anyone know how can i integrate this vi to the fpga vi (the one which I need to read/write data to 9870) as I need to send those data to control my epos2 controller.
    Please help me!!!
    Attachments:
    Encoder Position & Velocity (FPGA).vi ‏23 KB
    SINGLEMOTORMODIFIED.vi ‏17 KB

    Afai,
    As I allready suggested you here, call your local NI Office and ask for assistance!
    You really need assistence in a higher level that we can provide via the forums. Otherwise I don't see a chance for you to finish your project in time.
    1. Convert I32 to U8 to write it to the 9870 could be done like this:
    2. The vi to control the epos2.
    There is NO way ( absolutely NO way) to port this vi to FPGA. It's based on VISA calls, uses an event-structure, both are not available at the FPGA.
    The only thing you could do is to analyze the VI, the instruction set and design an FPGA vi which handles the specific instructions you would need.
    I have no experience with epos2 and I'm not 100% sure if this would work as you would like to use it. And doing this needs deep knowledge of LabVIEW, VISA, Instrument Drivers, the epos hardware, FPGA programming, and so on... 
    Christian

  • Problems reading xmp data into dng files

    Hi there,
    I am working on a Mac and have exported files as lossy dng for colour correction externally. They have done the work for LR 5 process (I am using CC) and returned xml files. I cannot seem to read this data into the dng files for further editing in Lightroom. I have tried re-importing them and I have tried reading metadata from file. Any help would be appreciated as I usually simply read the xmp to the original RAW but the RAW files are currently on an external drive in another country!!!
    Thanks,
    Andy

    Moominman wrote:
    I am basically trying to export xmp files from a set of low resolution dng files so that I can access my Lightroom edits in the RAW files. I have separated the RAW and dng files in different folders
    Hi Andy,
    I dunno how best to get extracted xmp files into the raw folders, but if you are comfortable with exiftool, you can use it to extract xmp sidecars from DNG files.
    If you want a turn-key solution which does not required you to futz with exiftool, then consider a free plugin I wrote:
    robcole.com - xEmP
    It will allow you to create xmp sidecars with all your DNG adjustments and metadata (which can then be applied to the non-dng raw files).
    However, if you won't need the DNGs in your catalog afterward, then the easiest way is to convert them back to proprietary raw format using this plugin (also free, and I wrote it):
    robcole.com - UnDNG
    Conceptually, you can think of it as converting the DNGs to proprietary raw format, but note: it doesn't convert anything, it just allows existing raw files that are NOT in the catalog, to replace the DNGs that are in the catalog. All adjustments and metadata and everything else will be preserved (just like when you convert a proprietary raw to DNG format).
    Rob

  • Which background process writes date into alert log file in oralce

    which background process writes date into alert log file in oralce

    Hi,
    AFAIK, all the background process are eligible for writing information to alert log file. As the file name indicates to show the alerts, so background process have the access rights in terms of packages (dbms), to write to alert log.
    I might be wrong also..
    - Pavan Kumar N

  • Entering information into a converted word document

    I converted my PDF into a word document. How do I enter information? I'm trying to "type" information onto an application.

    It doesn't seem to be.
    This is what I get and I can't type into it.
    Cannot Preview Filetype Please download the file for viewing.
    2
    Type
    Microsoft® Word (.doc)
    Added
    4:29 pm
    Modified
    4:29 pm
    Pages
    2
    Size
    132 KB
    Sharing Link
    unshare
    Report Abuse
    Download
    Rename...
    Share...
    Delete
    Exported Files
    Download All
    Employee Application1.doc
    Ready
    Download
    Remove History
    Sharing Link
    unshare
    Please Note: For the best experience accessing Acrobat.com files on a mobile device, use the Adobe Reader app on your mobile device.
    Use Adobe Document Services and access your files from any device
    English US (Change)
    Choose Your Language
    English US
    English UK
    Deutsch
    Español
    Français
    Italiano
    HelpTerms of Use Privacy Policy & Cookies©2012-2014 Adobe Systems Incorporated, All Rights Reserved.
    Acrobat.com
    Joan
    Help
    Ask Us a Question...
    Chat With Us...
    About Acrobat.com...
    My Information ...
    My Plan...
    Sign Out
    Files
    Create PDF
    Export PDF
    Combine Files
    Create Form
    Acrobat Plus
    Acrobat.com Files
    Filter by...
    Select Attribute
    Select Value
    View by:
    List 
    Thumbnail 
    Sort by:
    File Name 
    File Type 
    File Size 
    Date Added 
    Date Modified 
    Name
    Size
    Date Added
        Employee Application1.doc
    132 KB
    4:29 pm
        Employee Application1.docx
    51 KB
    4:03 pm
        Employment Application - January 2014 (1).doc
    771 KB
    01/13/2014
        Employment Application - January 2014.doc
    771 KB
    01/13/2014
        Employment Application - January 2014.docx
    312 KB
    01/13/2014
        Employment Application - January 2014.rtf
    771 KB
    01/13/2014
    There are currently no files in Acrobat.com.
    Upload your files to have access to them anywhere.
    (Note: Workspace files are saved at workspaces.acrobat.com)
    There are currently no files in Acrobat.com.
      Cannot Preview Filetype Please download the file for viewing.
    Employee Application1.doc
    File Info
    Cannot Preview Filetype Please download the file for viewing.
    2
    Type
    Microsoft® Word (.doc)
    Added
    4:29 pm
    Modified
    4:29 pm
    Pages
    2
    Size
    132 KB
    Sharing Link
    unshare
    Report Abuse
    Download
    Rename...
    Share...
    Delete
    Exported Files
    Download All
    Employee Application1.doc
    Ready
    Download
    Remove History
    Sharing Link
    unshare

  • How can FMS create a text file and write data into it in the Server application folders?

    Recently, I writed a programe about creating a text file and writing data into it in the server application folder. My code is as following:
               var fileObj = new File("/MyApp/test.txt");
               if( fileObj !=  null)
                      if(fileObj.open( "text", "append"))
                            fileObj.write( "                                                      ———— Chat Info Backup ————\r\n" );
                            fileObj.close( );
                            trace("Chat info backup document :" +  fileObj.name + " has been created successfully!");    
    But when I run it, FMS throw the error as following: File operation open failed  ;  TypeError: fileObj has no properties.
    Can you help me ? Thanks in advance.
    Supplement: The text file named test.txt doesn't exist before create the fileObj, an instance of File Class.

    Is MyApp the name of the application directory, or is it a child of the application directory? If myApp is the app name, just use test.txt as the path flag in the file constructor.

  • How can I read/write data files (text file) from PL/SQL Script

    I had an oracle forms pl/sql program to read/write a data file (text file). When this code is run on a command line as a PL/SQL script using the SQL*Plus I am getting an error:
    -- sample.sql
    DECLARE
      vLocation                 VARCHAR2(50)  := 'r:\';
      vFilename                 VARCHAR2(100) := 'sample.dat';
      vTio                   TEXT_IO.FILE_TYPE;
      vLinebuf               VARCHAR2(2000);
      vRownum               NUMBER        := 0;
      -- use array to store data FROM each line of the text file     
      TYPE           array_type IS VARRAY(15) OF VARCHAR2(100);
      vColumn      array_type := array_type('');
      PROCEDURE prc_open_file(p_filename IN VARCHAR, p_access IN VARCHAR2) is
      BEGIN
        vTio := TEXT_IO.FOPEN(vLocation||p_filename,p_access);
      EXCEPTION
        WHEN OTHERS then
          --  raise_application_error(-20000,'Unable to open '||p_filename);
          message(sqlerrm);pause;
      END;
      PROCEDURE prc_close_file is
      BEGIN
        IF TEXT_IO.IS_OPEN(vTio) then
           TEXT_IO.FCLOSE(vTio);
        END IF;
      END;
    BEGIN
      --extend AND initialize the array to 4 columns
      vColumn.EXTEND(4,1);
      prc_open_file(vFilename,'r');
      LOOP
          LTEXT_IO.GET_LINE(vTio,vLinebuf);
          vColumn(1)  := SUBSTR(vLineBuf, 1, 3);
          vColumn(2)  := SUBSTR(vLineBuf, 5, 8);
          vColumn(3)  := SUBSTR(vLineBuf,10,14);     
          Insert Into MySampleTable
          Values
            (vColumn(1), vColumn(2), vColumn(3));
          EXIT WHEN vLinebuf IS NULL;
       END LOOP;
       prc_close_file;
    END;
    SQL> @c:\myworkspace\sql\scripts\sample.sql;
    PLS-00201: identifier 'TEXT_IO.FILE_TYPE' must be declaredIt works on the oracle forms but not on the SQL*Plus. Is there an alternative method using a PL/SQL script? A simple sample would help. Thanks.

    Did you ever noticed the search box at the right side of the forum?
    A quick search (limited to this years entries) brought up this thread for example
    Re: UTL_FILE Examples

  • How to write data into a file

    Hi
    I want to write data from a string into a file. I am created a directory and a .doc file . But when i write this data from a string into .doc file , its give an error : File not found exception
    But, when i check in my directory, a file is created with blank.
    My code is:
    import java.io.*;
    import java.util.*;
    import java.lang.*;
    class createFile {
         public static void main(String[] args) {
    try {
         String mss = "This is for dedo";
         FileInputStream fis;
         FileOutputStream fos;
    File file = new File("C:\\JD\\m4.rtf");
    // Create file if it does not exist
    boolean success = file.createNewFile();
         success = true;
    if (success) {
                   System.out.println("suc");     
                   fis = new FileInputStream(mss);
                   System.out.println(fis);
              fos = new FileOutputStream(file);
              int c;
                   while ((c = fis.read()) != -1) {
         fos.write(c);
                   System.out.println("mss");
              fis.close();
              fos.close();
         System.out.println("created");
    // File did not exist and was created
    } else {
    // File already exists
    } catch (IOException e) {
         System.out.println(e);
    regards
    madhu

    InputStream inputStream = new ByteArrayInputStream(mss.getBytes());Use this to push into the file>
    Ummm.... no. InputStreams are for reading, not for writing.
    Anyway, OP, you're making a mistake. You're trying to open a stream to a file called "This is for dedo". Use FileOutputStream(File file) constructor or FileOutputStream(String pathToFile). You can then wrap that stream with a PrintWriter or whatever you need.

  • Reading decimal data into a string

    Hi,
    I am having an issue in converting the non char data like decimal into character.  Here is my code In the output I see '#' signs where I am supoose to get certain amount values in the decimal format. I require it because I need to download the data into a file. Any thoughts?  Rest of the code looks fine. Thanks in advance,
    VG
    field-symbols: <fs_table> type standard table,
                   <fs_wa>,
                   <fs_string>.
         CREATE DATA v_dref Type table of (v_tabname).
          assign v_dref->* TO <fs_table>.
          select * from (v_tabname) into table <fs_table>.
          loop at <fs_table> assigning <fs_wa>.
              assign component sy-index of structure <fs_wa> to <fs_string> casting type c.
              if sy-subrc = 0.
                write:/ <fs_string>.
             else.
               write: <fs_string>.
              endif.
            endloop.
    output:   10000100000001019999123120090101                                        ############0001

    @-Clemens - I tried your code , some problems with decimals values , adds a * in front.
    @Vinu - Just some rough modification to the code written by Clemens
    PARAMETERS:p_table TYPE tabname.
    DATA:wf_maximum TYPE i,
         wf_total_fields TYPE i,
         wi_count TYPE i,
         wf_ltype TYPE c,
         wf_length TYPE i,
         wi_index TYPE i.
    DATA:i_comp TYPE cl_abap_structdescr=>component_table,
          wa_comp LIKE LINE OF i_comp,
         wa_fields TYPE abap_compdescr.
    DATA:lr_data TYPE REF TO data,
         lr_line TYPE REF TO data,
         wf_data_str TYPE REF TO data,
         wf_type_struct TYPE REF TO cl_abap_structdescr.
    FIELD-SYMBOLS:<fs_table> TYPE STANDARD TABLE,
    <fs_wa>     TYPE ANY,
    <fs_line> TYPE ANY,
    <fs_field_s> TYPE ANY.
    CREATE DATA lr_data TYPE TABLE OF (p_table).
    ASSIGN lr_data->* TO <fs_table>.
    CREATE DATA lr_line LIKE LINE OF <fs_table>.
    ASSIGN lr_line->* TO <fs_line>.
    SELECT * FROM (p_table) INTO TABLE <fs_table> UP TO 20 ROWS.
    CLEAR:wf_ltype,wi_count.
    DESCRIBE FIELD <fs_line> TYPE       wf_ltype
                               COMPONENTS wi_count.
    LOOP AT <fs_table> ASSIGNING <fs_wa>.
      AT FIRST.
        wf_maximum = 0.
        wf_total_fields = wi_count.
        WHILE wi_count GT 0.
          wi_index = sy-index.
          ASSIGN COMPONENT wi_index OF STRUCTURE <fs_wa> TO <fs_field_s>.
          IF sy-subrc EQ 0.
            DESCRIBE FIELD <fs_field_s> TYPE          wf_ltype
                                        OUTPUT-LENGTH wf_length.
            IF wf_maximum LT wf_length.
              wf_maximum = wf_length.
            ENDIF.
          ENDIF.
          wi_count = wi_count - 1.
        ENDWHILE.
        CLEAR:wa_comp,i_comp[].
        wa_comp-name = 'FIELD'(005).
        wa_comp-type ?= cl_abap_elemdescr=>get_c( wf_maximum ).
        APPEND wa_comp TO i_comp.
        TRY.
            wf_type_struct =
            cl_abap_structdescr=>create( p_components = i_comp ).
          CATCH cx_sy_struct_creation.
        ENDTRY.
        CREATE DATA: wf_data_str TYPE HANDLE wf_type_struct.
        ASSIGN:wf_data_str->* TO <fs_line>.
      ENDAT.
      DO.
        ASSIGN COMPONENT sy-index OF STRUCTURE <fs_wa> TO <fs_line>.
        IF sy-subrc = 0.
          WRITE <fs_line>.
        ELSE.
          EXIT.
        ENDIF.
      ENDDO.
    ENDLOOP.

Maybe you are looking for

  • Domain machine Can't access administrative shares c$ admin$ on windows 7 x64 network path was not found

    Hello, I'm unable to access admin shares on a windows 7 pro x64 domain machine, i've tried the following: . Disable IPV6 . LocalAccountTokenPolicy (32 and 64 bits set to 1 or zero with restart) . Disable UAC . Disable firewall . LmCompatibilityLevel

  • Star up disk full on Macbook Pro

    I recently got a Pro and merged some files from my iMac onto it. I woke up the next day to turn on my laptop after letting the merging go through and now it says my start up disk is full and to empty it but after I click okay then the screen is compl

  • 27" imac (2009) as a monitor

    Hello I have 2009 27" imac (i5 750) Can i use my imac as a monitor with Gigabyte H55M-USB3 equipped pc? It has onboard display port. But i dont know its supporting 2560px resolution. http://www.gigabyte.com/products/product-page.aspx?pid=3444#ov Plea

  • How can i Get rid of verbal hel

    How can i get rid of the microphone that wants to help me when i don't want help? It talks to me and shows up unexpectedly, esp. When i'm on the phone, and i loose the call trying to get rid of it.

  • Settlement rule production orders

    Hi All, I want any report through on can see the settlement rule maintained for production orders.? Regards, MHP