WORD Docs and ASP.NET

C

cgia

The question is very general, I know.
I am reading a lot of info on the subject but can't really make up my
mind on the way to attack this.

I have portions of formatted text into the database (kind of
sentences, with the space for the address blank for example). The user
will choose the correct address from another table in the database. At
this point I would like to generate a Word document with the formatted
text including the right chosen address.
Ideally, the user will type additional text in the document (which I
would display in the browser with MS Word). At this point I would like
the complete document to be saved into the database or printed as a
pdf and the pdf saved into the DB.
Another question is how to save the document into the database when I
have it embedded in the web form.

Thanks!
 
K

Kevin Spencer

Using any Office product on the server side of a web application is
dangerous at best, and becomes more so with an increasing number of users.
Is there some reason that this text must be formatted and stored as a binary
file type? There are also performance issues with storing binary files in
any database. Perhaps you could just store and retrieve the text?

--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
Big things are made up
of lots of little things.
 
C

cgia

Thanks for your answers.
I am having some additional comments:

- I am not really obbliged to use MSWord in the browser, if this
creates the problem of using MSWord as server-side. What if I launch
MS Word in the client as an object Word.ApplicationClass from asp.net?
The application is into the intranet and every workstation has MS
Office XP installed.
- The documents to be produced/stored are actually 1-page contracts,
which I currently store in an SQL database from Paradox front-end as
pdf, and performances are OK. I guess the performances would remain
acceptable.
- My idea to use word is related to the formatting and spell checker
options it offers, but... what are my chances? How about editing from
text boxes in the browser and generate an RTF document this way?
- I cannot afford to purchase a third party product for several
reasons.

Could you tell me how feasible is the following solution?
1) I launch word as a Word.ApplicationClass from asp.net. (I saw
something in the following article:
http://www.codeproject.com/aspnet/wordapplication.asp. I think I
understand that this way I would execute MSWord as a client
application, removing the server side issues, right? Any special
permit to set this way?)
2) In such word instance I open a template (.dot) whose fields I would
fill in with data from the database.
3) In the template I would disable from the menu the "file/save" and
"file/save as" entries. I would create a new one like "file/save and
close word" whch would save the file in a temp folder, locally in the
PC.
4) Asp.NET uploads the file from the temp folder.

How else can I generate a kind of contract with asp.net, which can be
stored?
I am open to ANY idea. Thanks
 
C

cgia

Using any Office product on the server side of a web application is
dangerous at best, and becomes more so with an increasing number of users.

What is the process to use an Office product on the client side of a
web application, conversely?
Is there some reason that this text must be formatted and stored as a binary
file type? There are also performance issues with storing binary files in
any database. Perhaps you could just store and retrieve the text?

That would be perfect, but how to produce the contract document at
user's request?
 
C

cgia

Frantically :) reading on the subject, I see that the only way to make
word executable at the same time by several people is to execute it on
the client. In order to do it I guess I have to use client side
Javascript which opens word. But how abot the security settings in
these case? And how about the other steps of the process?
 
K

Kevin Spencer

What is the process to use an Office product on the client side of a
web application, conversely?

The client machine has the application installed, and downloads a document
that the application can read.
That would be perfect, but how to produce the contract document at
user's request?

That all depends on your requirements, which are ...? In other words, what
does the client require? Do they require that they can download a
dynamically-created document immediately, get one emailed to them, wait a
period of time, etc? Is it a requirement that this be a Word document? For
example, an RTF document is not a proprietary format.

--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
Big things are made up
of lots of little things.
 
C

cgia

Thanks for your reply.

Actually my requirements are that user are able to produce a contract,
and that the final copy is stored in the database.

In order for them to perform spell checks and formatting I have to let
them download the document locally (RTF generated in the server using
DB info) and edit it.
But once thay've done that, how can I save the final version of the
document back into the DB, in a kind of transparent way. Of course
they could:

1) save the document in a local folder
2) click an import button in the asp.net form
3) remove the local copy of the document

Any ideas to make it a bit smoother?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top