473,378 Members | 1,531 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,378 software developers and data experts.

To save html page as word document into database

Hi Friends

I am doing a project using requesthandlers and ejb. In that, the user is given a provision to enter his comments and suggestions in the text area provided in the html page. After entering his comments, these are stored into the database as blob and when edit is clicked these blobs are retrieved from database.
Now the actual problem comes. an option to save and preview is provided.

What i need is, on clicking save button the html page has to be automatically converted to word document and get saved into the database.Because if the user wants to preview, it should be displayed as word document and can be in the form of a report to be printed


i really need help and very soon

hope u all will help me
Feb 26 '07 #1
5 3519
r035198x
13,262 8TB
Hi Friends

I am doing a project using requesthandlers and ejb. In that, the user is given a provision to enter his comments and suggestions in the text area provided in the html page. After entering his comments, these are stored into the database as blob and when edit is clicked these blobs are retrieved from database.
Now the actual problem comes. an option to save and preview is provided.

What i need is, on clicking save button the html page has to be automatically converted to word document and get saved into the database.Because if the user wants to preview, it should be displayed as word document and can be in the form of a report to be printed


i really need help and very soon

hope u all will help me
When storing inthe database we do not store as .doc or .htm. It is the retrieve that should display as word. Just store into the database as Strings or BOLB or whatever supported datatypes. When you want to view the data, then get the data into required format for displaying.
Feb 26 '07 #2
When storing inthe database we do not store as .doc or .htm. It is the retrieve that should display as word. Just store into the database as Strings or BOLB or whatever supported datatypes. When you want to view the data, then get the data into required format for displaying.


Ok. I know that usually data is saved as blob into the database. but, the problem is, how to store the Template into the database?
by saving as blob and retrieving it will display only the contents. i need to display the heading and the content below that which is saved as blob in database.

And help me with the code to view the data and getting it into the required format for displaying
Feb 26 '07 #3
r035198x
13,262 8TB
Ok. I know that usually data is saved as blob into the database. but, the problem is, how to store the Template into the database?
by saving as blob and retrieving it will display only the contents. i need to display the heading and the content below that which is saved as blob in database.

And help me with the code to view the data and getting it into the required format for displaying
You have to find a way of string the template as text in the database or as an image.

You view the data by retrieving it using jdbc into a resultset object and then you can use a package e.g poi package to create a .doc for displaying the data as a .doc
Feb 26 '07 #4
Thanks for the reply

but, i would like to know , whether i can get the data in any required format without the help of any software. is it possible to do the same using javascript
Feb 26 '07 #5
r035198x
13,262 8TB
Thanks for the reply

but, i would like to know , whether i can get the data in any required format without the help of any software. is it possible to do the same using javascript
If you want a properly formatted .doc, you will hava to use a ready made Java package for that. You might have to ask in the Javascript forum to find out if the same can be done in Javascript.
Feb 26 '07 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Martin Lucas-Smith | last post by:
I am trying to use PHP's COM support to open a URL from within MS Word then save the document. I am using PHP5.0.3/Apache2/WindowsXP. phpinfo() confirms that COM support is enabled. ...
3
by: lee_j | last post by:
Hi, I have a question below. In the Sql server 2000 I store some word documents.Then I get the data from the database through the asp code and display the word document in IE.The ContentType is...
0
by: Steve Holland | last post by:
Hi, We have a web app which reads in a Word 2000 template (.dot), replaces some fields, then saves it off to the filesystem. This all works fine. What we would now like to do is to save the...
1
by: Danny | last post by:
Hi, I have a htm page that was generate by my application . I need to save it as word document automaticly (not by using file,save as...) by my application using C#.Net Thanks, danny
7
by: joseph.inglis | last post by:
I have a web browser object on a form which I have set to edit mode and use the UCOMIConnectionPointContainer interface to hook in and catch events. All working sweetly. Except there...
2
by: csgraham74 | last post by:
Hi, I have a requirement in work that i give a person the ability to create a html document using a richt text editor. What i then want to do is save the HTML doct to my server & insert...
2
by: gusa992000 | last post by:
Hello I am trying the following problem: A web app in jsp and java has to open a microsoft word document directly in the browser. This part is easy and i have done it. The user then can...
4
by: anilareddy | last post by:
Hi all, I have a problem in my project. I have developed a small page like this. Now after the save button is clicked, the data which is entered should be stored in the database. I'm attaching the...
0
by: ppardi | last post by:
I'm developing an addin for Word 2007 and I need to determine whether a user saves a Word 2007 document in an older format (97-2003) after a save as is done. The scenario is that the user starts...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.