JSP that converts office extensions to pdf and then upload them

Hi there !
Im trying to convert office extensions ( .xls, .ppt, etc) to pdf and then upload the resulting file to a server .
currectly im using the upload solution posted by the user anna_DRA here : http://forums.sun.com/thread.jspa?threadID=672874
and as for the conversion im using a solution which uses OpenOffice's lib to do the conversion.I'm going to post the codes of my JSP and my HTML ( which just contains the form to get the file to be converted and uploaded).
observation: the point which is giving me headaches is how to get the file sent by my form, convert it into a File object, use my conversion tool and then deliver it to my upload tool so it can be stored.... i cant seem to get the File object from the request object ( tried getattribute and it returns null....) .
observation':I do know about and how to use MVC but my boss asked me to make this work with just one JSP or a JSP and a HTML.
index.html :
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Upload test</title>
</head>
<body>
<form enctype="multipart/form-data" action="/WSPdfConversion1.1/Conversion.jsp" method=POST>
<input type="file" name = "FileUp">
<input type="submit" value="Enviar"/>
</form>
</body>
</html>Conversion.jsp :
upload portion:
MultipartFormDataRequest mrequest = new MultipartFormDataRequest(request);
OpenOfficeConnection OpenOfficeConnection = new SocketOpenOfficeConnection(8100);
String newName = "";
Hashtable files = mrequest.getFiles();
UploadFile file = (UploadFile) files.get("FileUp");//Give name u r given in the previous page.
String fileName = file.getFileName();
upBean.store(mrequest, "FileUp");conversion portion:
OpenOfficeConnection OpenOfficeConnection = new SocketOpenOfficeConnection(8100);
try {
    OpenOfficeConnection.connect();
} catch (ConnectException e) {
    e.printStackTrace();
File inputFile = new File("C:\\Users\\thiago\\Documents\\"+fileName);
for(int i = 0; i <= fileName.length() - 4; i++){
    String s = ""+fileName.charAt(i);
    newName = newName.concat(s);
File outputFile = new File("C:\\Users\\thiago\\Documents\\"+newName+".pdf");
//convert the spreadsheet
DocumentConverter ExcelToPDFConverter = new OpenOfficeDocumentConverter(OpenOfficeConnection);
ExcelToPDFConverter.convert(inputFile, outputFile);
OpenOfficeConnection.disconnect();Both work just ok when separated but i cant get both to work together....
Any help is much appreciated!!!
Thanks in advance
Edited by: thiagocbalducci on Mar 24, 2010 12:07 PM
Edited by: thiagocbalducci on Mar 24, 2010 12:09 PM

Hello TSN,
Test Screen Name wrote:
Picking just one point: PDF -> EPS -> PDF. This could not possibly do more than one page, because EPS is absolutely by definition a single page format. Therefore you must choose a page when exporting PDF to EPS.
Thanks for your response.
I was thinking Microsoft... which has allowed multi-page eps files for years. But you're correct, this is normally an unsupported .eps format.
I solved the problem over the weekend by doing the following:
1) I removed the suspect OTF font family but despite doing so, the folder still had two 'corrupted' but unused copies of an italic font. They refused to remove so I had to boot into Win7 SAFE mode to remove.
2) After complete removal of the OTF font family. I reinstalled the OTF font *BUT* only from a different repository (oddly, this other OTF font set is slightly larger per font).
3) Once installed, I tested with Flare, published and uploaded to Crocodoc SUCCESSFULLY. Yeah!
I don't have anymore time to test but the questions remain, such as, was it one or more of the following issues:
a) Flare has a problem handling some OTF fonts or cannot error correct (the way other programs do) for marginal fonts or font errors?
b) Was it the two corrupted fonts in the Windows/fonts folder?
c) Was it the slightly different OTF fonts that I am no longer using?
Take care

Similar Messages

  • How can I convert a word file into a pdf and then upload to a web site?

    I need to convert a word document into a pdf and then upload it to a web site so people can read it from my
    site. How can I do this? Can anyone please help? I'm only a newbie. Thanking you in anticipation.

    Hi there,
    There's actually an easy streamlined way to do this using Acrobat.com. Here are the steps:
    1. Log in to Acrobat.com with your Adobe ID.
    2. On the left, you'll see a navigation menu that includes the item "Import and Edit". Click that.
    3. Choose the .doc (Word) file you want to convert and upload it to Buzzword.
    4. After making sure that it looks the way you want it to, go to the top menu (still in Buzzword now, not the organizer where all your files live) and click the document menu. There will be an option to "Export" - choose that.
    5. When prompted to select filetype, choose "Adobe PDF" and press OK.
    6. It'll save to your desktop, so now you have to get it into your acrobat.com organizer. To do that, close the Buzzword document by clicking the little "x" in the upper right corner, under the Sign Out button. This'll get you back to your organizer, where you can choose "Import" from the left nav menu again. This time choose your new PDF file.
    7. Select the  file icon in the organizer and click the Share button. Or, select Share  from the file context menu.
    8. Select Allow Anyone With A  Link To Share This Document to set the document to open access, and then  click Copy Embed Code. The necessary HTML code to embed the preview is  copied onto the clipboard.
    9. Open the HTML file and paste  the code into the file. The Flash previewer can display any file type  that you can convert to PDF.
    Hope this helps! Good luck, and let us know how it works out.
    Rebecca

  • How do I convert a word document into a pdf and then upload it to a web site

    How do I convert a word document into a pdf and then upload it to a web site so people can read it from my
    site with Dreamweaver 4?. How can I do this? Can anyone please help? I'm only a newbie. Thanking you in anticipation.

    First you need to install a means of printing to pdf from word.  I like cutepdf writer ( http://cutepdf.com/Products/CutePDF/writer.asp ).  Once installed you will print the doc in word and under the printer selection you choose pdf.
    Once you have the file you put it in your local site folders and upload it using Dreamweaver.  Be sure to link to it from a page so users can get to it and I would recommend giving the link a target of _black so it will open in a new window (see the properties inspector in DW).

  • Does any one know of software that you can import a PDF and then draw  on it, dimensions, notes and symbols...technical drawing?. Blue beam have the perfect software for this BUT it's not Mac compatible

    Does any one know of software that you can import a PDF and then draw  on it, dimensions, notes and symbols...technical drawing?. Blue beam have the perfect software for this BUT it's not Mac compatible

    You need a PDF editor, at the high end use Adobe's Acrobat Professional, at the low end use the editing features in Preview (pre-loaded on your iMac). However you should probably look at the Mac App Store, you will find many of PDF editing applications. You simply need to find one that suits your needs.

  • Can I convert 100 Tiffs to PDF and auto save them simultaneously?

    Can I convert 100 Tiffs to PDF and auto save them simultaneously?  I prefer to not have to use "Save As" for every single one.
    Thank you for your time.

    http://answers.acrobatusers.com/I-convert-800-000-tiff-document-images-pdf-OCR-images-What -efficient-method-q42554.aspx

  • Is it possible to save an iPhone back up and access the files later if needed?  I have a string of text sms and iMessages that I would like to save and then delete them from my phone.  Is this possible?

    I have a string of text sms and iMessages that I would like to save and then delete them from my phone, but gain access to them later if I need them.  I prefer to have the string with the date/time stamp vs copying and pasting into a doc or text file.  Is this possible?

    Not unless you buy an app that accesses data from an iTunes backup.  Check in the app store.

  • I have recently purchased an Ipod with 2430 tunes stored on it and I wish to transfer these tunes to Itunes and then upload them to another Ipod.  How do I do this please?

    I have recently purchased an Ipod with 2430 tunes stored on it and I wish to transfer these tunes to I tunes and then upload them to another Ipod I own.  In plain speak how do I do this please?

    On-The-Go Playlists, created on your iPod Classic, are added to your iTunes Library when you Sync the iPod to the same iTunes Library that you have been using up to now.
    But note that On-The-Go Playlists, saved on the Classic, are named as New Playlist 1, New Playlist 2, etc. and are listed at the end of the Playlists. When you Sync your iPod with its iTunes Library, those saved Playlists are transferred to the Library, renamed as On-The-Go X (where X is the next available number) and then added back to your iPod with the new name. They will also be in correct alphabetical order, so they will be in the Playlists list under O for On-The-Go.
    If you also have an On-The-Go Playlist on the iPod (which has not been saved), that too will be uploaded to iTunes in the same manner.
    For some unknown reason, you will also probably see one extra, but empty, Playlist created in iTunes. This is a bug, which may get fixed one day! Until then, you simply have to delete in in iTunes.

  • I download songs from my dropbox to my macbook pro and then upload them to my updated iTunes.  iTunes plays them in entirety, but when i update my iTunes match, my iPhone and iPad skip many of the songs and albums.  Why?  I have tried everything.

    I download songs from my dropbox to my macbook pro and then upload them to my updated iTunes.  iTunes plays them in entirety, but when i update my iTunes match, my iPhone and iPad skip many of the songs and albums.  Why?  I have tried everything.

    If you have manually manage set, you do not sync.
    If you want to sync, select the content desired to sync and sync.
    This is all covered in the User's Guide.

  • How do i convert mac pages to pdf and then edit

    How do I covert a mac pages document to a pdf and then edit it?

    It can't be done using Adobe Reader.
    I'm not sure what "Mac Pages" is but typically, you would make changes to those original documents and THEN create a pdf. Editing a pdf can be anything from tedious to impossible depending on what you are trying to edit.

  • Save my resume in pdf and then upload into an online application

    IPAD 3 G
    frankly I am DISGUSTED with the LACK of productivity available on the IPAD.
    i bought "THE BEST" so that I wouldn't be disappointed......what a rip off
    another writer said it best..... apples a good for CONSUMING MEDIA... surfing, email, etc
    BUT if you need to write or edit a document...you might as well pull out your ten year old PC laptop 
    Here is MY proof in the form of a question;
    HOW DO I SAVE MY RESUME IN A STANDARD FORMAT, DOC, DOCX OR PDF...IN MY IPAD AND THEN
    HOW DO I UPLOAD IT TO AN ONLINE JOB APPLICATION.
    PLEASE..... if you are going to refer  steps or apps THAT I HAVE TO DOWNLOAD / BUY PLEASE REFERE ......ONLY...
    to apps you have personally proofed.....
    I can...not....STAND....... this TOY......it is USELESS....AS  A  TOOL FOR PRODUCTIVITY.
    TALK ABOUT LOWERED EXPECTATIONS.
    so i just tried to select the type of equipment I am using..... AND IPAD 3 G isn't even on the list!!!!!!

    There is much to agree with on both sides of this argument. Yes it's just a tablet and not a full blown PC but at the same time, how pathetic it is if a website asks you to upload a document and all the iPad will do is look in the pictures folder? This is so frustrating that's it's actually quite annoying!
    So picture the scene, you've got a really important document or CV to upload to a generic website and all the iPad (or iPhone) can do is look straight at your photo's. GREAT, that'll really help me out, ...erm NO!!
    As a user we can't change the website and we can't certainly change the OS on the tablet so where does that leave you? That's right, going on a wild goose chase looking for a free app that will change your document into a picture, just so you can upload it. It's just not productive at all. And before you say get Dropbox or Onedrive etc, I already have them. The website your trying to upload to can't get past the 'straight to pictures' problem i mentioned above. Infinite loop ensues...
    To be honest, if your iPad or iPhone has Apple Pages on it, why doesn't the device allow you to choose from that as well? That would put an end to this lack of productivity and eventual apple device annoyance. So going back to your original complaint, I agree, I find my iPad to be more of a toy than a work station, and I will only change my mind when Pages is better integrated to be of actual use in Safari and other essential apps.

  • Need library that lets me kill Windows programs and then reopen them.

    I have issues with a certain program crashing in remote locations..cough* VzAcess. I want to create a program that tries to ping a website and if that fails then it will kill the program and then re open the program. Everywhere I look line these three libraries come up:
    import org.javagroup.process.ProcessManager;
    import org.javagroup.process.ProcessManagerHolder;
    import org.javagroup.process.JProcess;
    I cannot find anywhere where to get these. Maybe my google skills have diminished. I don't know. If anybody knows of any good and reliable libraries that let me do these things that would be great. Thanks!

    dothedru22 wrote:
    ... Everywhere I look line these three libraries come up:
    import org.javagroup.process.ProcessManager;
    import org.javagroup.process.ProcessManagerHolder;
    import org.javagroup.process.JProcess;
    I cannot find anywhere where to get these. Not sure they do what you expect.
    jsh seems to be an abandoned project; no activity since 2001/2002.

  • Merging PDFs and then saving them as one file in Leopard

    Would someone please tell me how I can merge PDF files into one PDF file. I have been able to drag and drop them together in Preview. I would love to be able to save the merged files into one file. Any ideas. I have read a lot online about this possibility in Snow Leopard, but I can't seem to save the dang file.
    Help.

    Open the first PDF. Open the tray so you can see the file on the left. Drag the other PDFs onto the first file in the tray. You can't just drag into the tray window anymore, you have to drag onto the file itself to merge. Save the file with new name.
    Macmost has a good podcast on this subject that came out about a week ago. Shows other PDF tricks with Preview as well.

  • Export Office docs as PDF and have it indexable by SP

    Hi there...this is somewhat of a hybrid question between Adobe Acrobat and SP.....I'm taking a stab at this forum first...
    Long story short, we have a publishing server that converts office documents to PDF using Adobe Acrobat X as the engine that does the PDFing.
    Note: PDF mimetype is added and iFilter is in place and working.
    We've noticed that the contents of the PDFs created in this manner are not being indexed by SP and thus not searchable. 
    Yet, if we take the same excel file and just use the out of the box (Office) "save as" PDF, the document is indexed and the contents are searchable.
    But when we do the "Save as" adobe pdf (which uses adobe as the engine), it's not.
    I believe this is probably a configuration in Acrobat that I can simply switch on/off, but I can't find any documentation that really relates it to SharePoint indexing.  Anyone have any ideas?
    Thanks in advance,
    Eric

    Hi Eric,
    According to your description, my understanding is that the converted PDF file could not crawled in SharePoint 2010.
    Please go the Crawl log to check whether there are some errors for your content source.
    Make sure your search service account has proper permissions on the Adobe Filter binary folder.
    Please check if the link is useful:
    http://sharepointconnoisseur.blogspot.jp/2011/04/why-sharepoint-2010-search-does-not.html
    If this issue still exists, please install SP1 or the latest CU for SharePoint 2010, compare the result.
    I hope this helps.
    Thanks,
    Wendy
    Wendy Li
    TechNet Community Support

  • CONVERT SCANNED FILE TO PDF AND SEND TO EMAIL!

    I got many files that were scanned in (110) to be exact.  I need to know how to convert the scanned files to pdf and then send them to an email.  Thanks      Marie

    What is the format (file type) of these scanned docs?

  • Acrobat - Convert Office documents to PDF so that it is crawled/indexed by SharePoint search

    Hi there,
    This is a hybrid question between Acrobat and SharePoint and I'll post on both forums....
    Background:
    In a fairly complex application we have a publishing server that utilizes Acrobat to convert Office documents to PDF using the Convert to PDF functionality.
    We then publish that PDF to a library in SharePoint.  We would like to have those published PDFs searchable by SharePoint search.  Unfortunately there is something about these PDFs where SharePoint cannot crawl the content.
    Note:  I do realize that PDFs are not indexable by SharePoint out of the box and I have installed and configured the iFilter utility.  I have been able to index and search for other PDFs, so I know the mechanism works.  It just seems to be these
    particular PDFs.
    I have also manually "Saved as PDF" directly from Word/Excel and those PDFs are crawled by SharePoint....it just seems to be when Acrobat does its conversion.  I'm sure it's just a simple configuration somewhere... I just don't know what I'm
    looking for.
    Another note:  When I open the published PDFs, I am able to use Acrobat's search to find the text.... and the text is selectable; so it's not as if the conversion changed it to an image.
    So....would anyone happen to have encountered this issue?  Or does anyone know what makes a PDF indexable by SharePoint search?
    Thanks in advance

    Hi  ,
    According to your description, my understanding is that the PDFs which are converted from Office documents by Acrobat cannot be crawled in your SharePoint 2010.
    For your issue, please make sure these PDFs version is 1.5(Acrobat 6.x) or above.
    You can take steps as below for verifying:
    Open your PDF using Adobe Reader.
    Go to File -> Properties.
    Check the PDF Version under Advanced section.
    Best Regards,
    Eric
    Eric Tao
    TechNet Community Support

Maybe you are looking for

  • Oracle 9i on linux 7.2

    I have tried installing oracle 8i and 9i on linux redhat 9 (version 7.4.20) and (version 7.2) multiple times. I have followed all the instructions on the following links: http://www.oracle-base.com/articles/9i/Oracle9iInstallationOnRedHatAS3.php http

  • InvocationTargetException at Tomcat Startup

    I am seeing the following error appear in my catalina log after starting Tomcat on Red Hat Linux 8.0 using jdk 1.4.1... I am able to run servlets and JSP pages from the browser as well as within my application but would like to know more about this e

  • Getting List of Workbooks or Queries by Info Area

    Hi All, I want to find and categorize all workbooks/queries by Info Area I understand that this information could be found under Metadata Repository. But there are 4000 workbooks/queries which I want to categorize and I was searching for for backend

  • I need to deactivate the 2 work computers that I had my copy of Photoshop Elements 9 and activate my MacBook

    Any ideas on how to deactivate 2 computers at a business where I am no longer working?  I want to activate my 2 computers at home....

  • Cancel my plan

    I followed Adobe's instructions to upgrade DW CC 2014 from trail to full version by buying the "student and teacher plan", which has price 300 thb/month. Now I have been informed that this plan doesn't consist of DW CC 2014. I want to cancel this pla