Results 1 to 6 of 6
  1. #1
    sehudson's Avatar
    sehudson is offline Senior Member
    Join Date
    Mar 2010
    Posts
    340
    Rep Power
    5

    Default Print an external file from Java or JavaScript

    Is there a way to print an external file (.doc) using Java or JavaScript.

  2. #2
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    16,586
    Rep Power
    23

    Default

    Yes, a java app can read and print any file. The output may not be formatted as you'd hope for, it would depend if the programmer has the rules for formatting the content of the file.

    No idea what javascript can do.

  3. #3
    sehudson's Avatar
    sehudson is offline Senior Member
    Join Date
    Mar 2010
    Posts
    340
    Rep Power
    5

    Default

    so How would I do this?

  4. #4
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    16,586
    Rep Power
    23

    Default

    Read some of it, print it, read some more, print some more.
    If you need some code written, hire a programmer.
    If you need help with your code, please ask specific questions about what you are having problems with.

  5. #5
    sehudson's Avatar
    sehudson is offline Senior Member
    Join Date
    Mar 2010
    Posts
    340
    Rep Power
    5

    Default

    Ok, I guess my question wasnt clear.

    I am referring to printing to a physical printer.

    Let's say I have a file on my C: drive called MyFile.doc, and I want to (from within my Java Swing application) have that file sent to the printer.

    Can that be done.

  6. #6
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    16,586
    Rep Power
    23

Similar Threads

  1. How to print a HTML file in browser look using JAVA
    By ammameiya in forum Advanced Java
    Replies: 5
    Last Post: 06-25-2010, 02:36 AM
  2. How to print a HTML/JSP span using javascript?
    By sayan751 in forum JavaServer Pages (JSP) and JSTL
    Replies: 1
    Last Post: 09-14-2009, 06:38 AM
  3. Print .prn file using java
    By nishant in forum Advanced Java
    Replies: 0
    Last Post: 07-14-2009, 09:15 AM
  4. Print the text file and print preview them
    By Java Tip in forum java.awt
    Replies: 0
    Last Post: 06-22-2008, 11:04 PM
  5. External JavaScript files not loading
    By sajut in forum New To Java
    Replies: 0
    Last Post: 02-15-2008, 05:47 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •