Apache Word Help
I am trying to open a word document and write something different to it i have this so far but everytime i go to write the file it doesn't write and give me this error:
java.io.FileNotFoundException: Testing
(The filename, directory name, or volume label syntax is incorrect)
at java.io.FileOutputStream.open(Native Method)
at java.io.FileOutputStream.<init>(FileOutputStream.java:179)
at java.io.FileOutputStream.<init>(FileOutputStream.java:70)
at Encrypt.findFile.writeFile(findFile.java:108)
at Encrypt.findFile.getContents(findFile.java:77)
at encryption.Main.main(Main.java:39)
HWPFDocument doc = null;
public String getContents()
int arrlen = 10000;
byte[] infile = new byte[arrlen];
Frame parent = new Frame();
FileDialog fd = new FileDialog(parent, "Please choose a file:",
FileDialog.LOAD);
fd.setVisible(true);
String selectedItem = fd.getFile();
if (selectedItem == null)
// no file selected
else
setFileName(fd.getDirectory() + File.separator + fd.getFile());
File ffile = new File(getFileName());
// read the file
System.out.println("reading file " + getFileName());
try {
FileInputStream fis = new FileInputStream(ffile);
BufferedInputStream is = new BufferedInputStream(fis);
try {
doc = new HWPFDocument(new FileInputStream(ffile));
WordExtractor wd = new WordExtractor(doc);
String filestring = wd.getText();
writeFile(filestring);
return filestring;
catch(IOException iox)
System.out.println("File read error...");
iox.printStackTrace();
catch (FileNotFoundException fnf)
System.out.println("File not found...");
fnf.printStackTrace();
return null;
public void setFileName(String file)
fileName = file;
public String getFileName()
return fileName;
public void writeFile(String str) throws IOException
OutputStream word = new FileOutputStream(str);
doc.write(word);
}
Why not call JFileChooser#getSelectedFile(), which will return a java.io.File instead? You can pass that to your FileInputStream's constructor. That should be (relatively) bullet-proof.
- Saish
Similar Messages
-
Download Oracle SQL*Plus help related like word help
Hello all
I just wanna ask if where i can download Oracle SQL*Plus help related like word help.?
ty<p>You can access SQL*Plus help from the command line in a SQL*Plus session by typing 'help index'. If you want more information than that, take a look at the SQL*Plus Quick Reference located <b>here</b> or the SQL*Plus User's Guide and Reference located <b>here</b>. These docs are all for Oracle 10g. Other version documentation can be found <b>here</b>.</p>
Tom -
I turned on my word 2013 today and now get an error message that "word help is not working got to office.com"
All the other office suite helps are working just fine. If I use another profile help function also works, but that means creating all my files and shortcuts and everything I have set up in my default profile.
I have downloaded the 2013 suite again.
Anyone I need help!!!Hi,
Please try the steps below and let me know if it works:
1. Press Windows key + R to open the Run command.
2. Type or copy/paste the following command in the Run box:
%programdata%
3. Rename the'Microsoft Help' folder to 'Microsoft Help. OLD'
4. Run a repair of your Office installation. See:
http://office.microsoft.com/en-in/excel-help/repair-office-programs-HA010357402.aspx
Hope this helps.
Regards,
Steve Fan
TechNet Community Support -
Hi,
I'm trying to insert a JPanel based ActiveX into Words documents, I've used the Sun example (http://java.sun.com/j2se/1.4.2/docs/guide/beans/axbridge/developerguide/index.html) but it doesn't work.
When I try to insert the JellyBean exemple in a Word document, Word systematicaly freeze.
I don't understand, the ActiveX component works fine in VB 6.0 and in the ActiveX Control Test Container.
What I do :
1 - Compile JellyBean
2 - Jar it with a Manifest telling that it's a javabean
3 - Register it with the packager
4 - Run Word
5 - In the Component Tool bar, I choose "Other Controls" and select my component
=> At this moment the sandglass appears and nothing else happens
My environement :
SDK : 1.4.2_04
Visual C++ 6.0
Windows 2000 Pro
Any help will be greatly appreciated.
Olivier
PS: I've tryed to use SDK 1.3.1 and the old packager but this is worse => Word crash when I insert the component...I've found a solution but it doesn't satisfy me plainly ...
With visual basic, I've embedded the component generated by ActiveX Bridge into an OCX.
Doing this I'm able to insert the component in an office document but it isn't refreshed (Only a grey box is displayed). To refresh it, I call the activate method on the component in a VBA script.
Does anyone knows a more simple way to do the stuff ?
Olivier -
I can't export a PDF scanned file into WORD, help please.
I can't export a PDF scanned file into Word, please help.
Hi solarpowerprincess,
Are you having trouble signing in to your subscription, or having trouble converting files once you're signed in. If you can't sign in, it could be that your subscription just hasn't finished processing yet. Please let us know if you're unable to sign in and we'll go from there.
Best,
Sara -
Hyperlinks not generating properly in Word help
Robohelp 6 build 099
Hi
I am trying to generate a Word doc - as I have done several time before without any significant problems - and my hyperlinks, after several successful runs at the document for formatting purposes, now no longer resolve as hyperlinks .
What was back to top, for example, now looks like { HYPERLINK ""\| "02_songs_window_htm_songwin_6362" }
This applies to all hyperlinks in the document. A chm compilation is perfectly OK, however.
It looks like I've broken something, but I have no idea what. This is the first time I've seen this. Can anyone help?
With thanks
Robin Valk.
Message was edited by: R-VIt sounds like you have changed a Word setting.
Take a look at "Show field codes instead of their values"
See www.grainge.org for RoboHelp and Authoring tips
@petergrainge -
I started a pdf document (without saving it) and when I logged back on - all my Word documents got converted to pdf. Help
rosemerimarlo69 wrote:
when i convert pdf file in to the word then table content are not converted properly.
pease help me to solve this problem.
i tried many times but not success.
thankig you.
[spam link removed]
Please stop posting that spam link, even if it's just for a dead website! -
Word help- different first page header
How do can I make the text in the header on the first page of my word document, different from the information on the rest of the headers. I am using APA formatting for my school paper.
Thanks!The best place to look for help with Word in on the Microsoft Office Support pages.
Jerry -
Please help i can't open file or application such as notepad I am using Captivate 7
Hi Lilybiri
I am trying to link and open application using text captions function eg: assessment in a MS word Document
text Caption hyperlink
Under Hyperlink dialog " Link to: Open File.
C:\Users\ntan\Documents\My Adobe Captivate Projects\assessment_info (9681).docx
Note: Worked fine under preview mode , by once publish linked are broken
Publish error
Error as follow:
File not found
Firefox can't find the file at
\Users\ntan\Documents\My Adobe Captivate Projects\assessment_info (9681).doc
Check the file name for capitalization or other typing errors.
Check to see if the file was moved, renamed or deleted.
your help would be much appreciated.
Thank in advance -
hi, Ive never had a problem with my macbook yet but i installed microsoft word about a month ago and now it seem to stop working, i used it this week(on monday) but now it wont seem to open. it just bounces and i tried to open up the other application (powerpoint, excel, etc) and they bounce twice and then nothing happens. any help? what shall i do since i need it for school.
blackbook Mac OS X (10.4.7)You should also try to update your permissions, this is advisable at least once a month. To do it properly it is advisable to reboot your laptop at the end, so finish any pending work before you try it so you can reboot your laptop afterwards.
To repair permissions, go to
Applications>Utilities>Disk Utility
Then on the left margin, select your Macbook's hard drive (where you have OS X and Word installed).
At the right hand bottom of the screen you should have a couple of buttons and one should be repair permissions. Press it.
When it finishes, restart your computer. You are done! -
I had set up my Apache and PHP via the terminal last year, and had it working properly in the browser under localhost. I stopped working with it for a year, and am now trying to figure out how to get it up and running again. I have a bad feeling that it's been somehow wiped out. I open a terminal window, type in the command to start apache, it asks me for my root password, accepts it, but then opens up an empty PICO window. I have no idea of where to begin trouble shooting this. Any help would be appreciated.
ibook Mac OS X (10.3.4)The file that causes the "starting apache" isn't located in the Apache directory -- it's somewhere in /etc .
Updating the OS can occasionally wipe out non-standard installations -- Apache 2 being one such. That's why I remarked that version 1.x is a fine option -- OS X manages it and doesn't kill customizations you make to configurations (as in httpd.conf).
So you can try to get PHP working with Apache 1.x. Or you can try installing Apache 2 again. Make sure you follow instructions specifically for OS X, and make some notes about what you did (put comments in the configuration files, and send yourself an email with links to the instructions, a list of the files you changed, etc).
But sometimes the easiest way to go is to do a clean install of the OS. That puts everything back to where it's supposed to be, and you can take small steps customizing things. You no doubt have a lot of detritus piled up in your system.
Other people definitely think that my way is a bit radical, so before you take my advice, see if someone comes up with some better advice.
Also, let me recommend that you find a quick tutorial for Unix and Terminal. SInce you want to work with some non-standard, non-GUI apps, you will benefit from having some really basic commands (cd, ls, chmod, sudo, tar for example). Here's a good one: <http://www.macdevcenter.com/pub/a/mac/2005/05/20/terminal1.html> -
I am having trouble installing CF8 Ent. I can get it to
install correctly but when I try to start coldfusion it runs the
apache connector wizard and get a message saying "coldfusion 8 not
started. Retrying ..." It does this 12 times and although it says
it has started, it has not. So I assume I am setting up the
connection to Apache incorrectly however I am following the
directions found here (and which worked in Red Hat 4):
http://gayanonline.blogspot.com/2008/02/how-to-install-coldfusion-8-on-linux.html
The only change to those directions that I made was to the
script file. Instead of /etc/init.d/httpd I am using
/etc/rc.d/init.d/httpd.
What am I missing and doing wrong?
Thanks for any suggestions and help.Ok here is the current status:
I have "installed" CF8 Ent but cannot get it to start up (see
first post). I am finding that although I am going in and manually
changing the paths in apache_connector.sh and attempting to start
ColdFusion the wizard will just not do what it is supposed to. Now
I have enough information to make the changes to httpd.conf, but
the thing I have noticed is the folder that is found in
/runtime/wsconfig/(number) is also not being created. Is this
something I can do manually? If so what files, do I need? -
Where are the answers posted?
I am [email protected]
I have been using a computer for several years BUT this my first time to be trying to use any thing ADOBE.
Just about 4 hrs ago, I paid for a 1 year fee.
I am lost I simply want to print out some Adobe material I saw on the WEB. I really need to be able to print it out today.
The material IS NOT "sheltered" or protected. I see the pages BUT cannot get it to print.
I have Microsoft 7 and Explorer 8 Word and Microsoft "Works"
I believe this message has been taged on to someone else's. But I was unable to get an outgoing message. If anyone see's this and can help I would be glad to pay for a phone call if needed. Thanks
[email protected] -
Converting PDF to Microsoft Word - HELP!
I have Adobe Acrobat 8 Professional, and have been unable to
successfully convert PDF documents into Microsoft Word documents. I
usually get the following message: "Save as failed to process this
document. No document was created."
After restoring the setting preferences to their default
status, I was able to save the document into Word. However, it was
not a true Word document, since I COULD NOT EDIT IT. This has been
extremely frustrating.
Wondering if anybody has any advice.
Thanks.
Jeff Zajacquote:
Originally posted by:
mariajef
I have Adobe Acrobat 8 Professional, and have been unable to
successfully convert PDF documents into Microsoft Word documents. I
usually get the following message: "Save as failed to process this
document. No document was created."
After restoring the setting preferences to their default
status, I was able to save the document into Word. However, it was
not a true Word document, since I COULD NOT EDIT IT. This has been
extremely frustrating.
Wondering if anybody has any advice.
Thanks.
Jeff Zajac
I have the same problem. Help!!!! I'm in a work environment
and unalbe ot install adobe flash. I need printed instructions on
converting to word -
Emergency!! Microsoft word help please.
Ok I have a paper due on Monday for my English class, however whenever I open Microsoft word it just freezes on me and I keep having to force quite. Is there a way I can fix this? I have already sent a message to report the error, but I don't know if they will get it fixed before Monday. Please help.
And thank you for your time!!
P.S. it is Microsoft word 2004 and excel and powerpoint work just fine.
Message was edited by: Said JawadAltrnatively you could try opening your Word docs in Pages, if you have it, or a trial version of pages. I've done this in the past when caught out with Word not working.
You can also export to Word format from Pages so that when you get Word working again you can continue using it for your college/uni projects.
Good luck with the paper you are writing!
Barrie
Maybe you are looking for
-
How to install windows xp on mac mini without cd rom support
How to install windows xp on mac mini without cd rom support. I have installed Bootcamp on my mac mini. And i was using windows xp on my mac mini before xp crashed due to a system file missing or corrupt.
-
Adobe Illustrator Will Not Startl
So...I don't know what's going on. Last night I was using Illustrator CS2 just fine and dandy. Took my computer to work with me as I usually do...used it throughout the day like I usually do...then when I got home I proceeded to get open Adobe Illust
-
Adobe acrobat has stopped working and i cant open or create pdf's
adobe acrobat has stopped workining and i cant open or create pdf's
-
I have a corrupted bookmark file and want to totally delete any information on the bookmarks and settings. I have deleted any files which reference Mozilla and Firefox from my hard drive and have gone into the Registry and deleted all references to F
-
Does anyone have a script to scan subfolders and relink images. Scenario - InDesign file contains numerous images that have been moved to various subfolders in a new server. The main path I can change, but I need to scan the subfolders and relink the