Word 2003 + VB.NET

G

Guest

Hi,

Its like a I am searching alot but still not found or satisfy what I found it.

My question is that I had SQL server that contains some data.
I also have a application folder call CUSTDOCUMENT.

Once user cliks a button to retrive a document about the customer I need to
program in this order:

1-I want my user to creat word like document using RichText like component.
MS RichText cannot allow mw to accomplish many formation like we do use
normal Word Document. Then once user types the information about customer he
must also have to save it in predifine folder with predifine name. Example
once the user going to create new customer say ID NO 8, the application
automaticaly creates a empty word document as 0000000008.doc in application
CUSTDOCUMENT folder.

But before it going to create a empty word document it ask user that if they
wish to write someting. If yes then new form opens and they can type anything
about customer in RichText components like textbox. Than in the new form when
they click the SAVE button the document name itself automaticaly as in in
above example
and saves as 0000000008.doc in application CUSTDOCUMENT folder.

2- When user browse the customer information with the application the form
cosist of the customer data and button also poonts the where the word
document is located. Then is user clciks the OPEN button the form that
cotains RichText like components will open and shows the user about the
content of the document that belongs to current Customer that they are
viewing.

For this reason I created RichText like form but I am faild to open any
document or write it. All I need is the kind of component that allows me to
type a MS word document kind of text and if user wants to use the Font.Bold
in certain text than they have to do it. The rich text doesnot alllow to use
it in ceartain text to be bold.

So here is my question. How to achive this? Or where I can get good example
of the
application that does the things that I explained in above.

I can use excel kind of grid or html in Windows Form but why I am not be
able use it the word document in VB.NET 2003.

Does anyone out there to help me, or am I asking too much that is not
possible?

I realy appricate that you spend time to reading my post. And I thank you
for that.

Regs,
Niyazi
 
G

Guest

Good luck with your search, as far as I know there are no controls or
libaries that you can use to achive this.. I've searched for 'm to! However,
you might be able to do this, by reading out the word document!

word.application.visible = false
word.document = word.application.document.open "your document.dot"
lsText = word.document.range.text

Hoever, you will have separately read out the font's, fontsize's, bold
properties and all other things you want.

There might be another possibility that I am just thinking of: Try to save
it as a temporary file and save it as a word 6 format.... Richttextbox can
read that out!!!!
Don't know if office 2003 can do that but it worth a try!


Michel
 
R

Radenko Zec

Niyazi said:
Hi,

Its like a I am searching alot but still not found or satisfy what I found
it.

My question is that I had SQL server that contains some data.
I also have a application folder call CUSTDOCUMENT.

Once user cliks a button to retrive a document about the customer I need
to
program in this order:

1-I want my user to creat word like document using RichText like
component.
MS RichText cannot allow mw to accomplish many formation like we do use
normal Word Document. Then once user types the information about customer
he
must also have to save it in predifine folder with predifine name. Example
once the user going to create new customer say ID NO 8, the application
automaticaly creates a empty word document as 0000000008.doc in
application
CUSTDOCUMENT folder.

But before it going to create a empty word document it ask user that if
they
wish to write someting. If yes then new form opens and they can type
anything
about customer in RichText components like textbox. Than in the new form
when
they click the SAVE button the document name itself automaticaly as in in
above example
and saves as 0000000008.doc in application CUSTDOCUMENT folder.

2- When user browse the customer information with the application the form
cosist of the customer data and button also poonts the where the word
document is located. Then is user clciks the OPEN button the form that
cotains RichText like components will open and shows the user about the
content of the document that belongs to current Customer that they are
viewing.

For this reason I created RichText like form but I am faild to open any
document or write it. All I need is the kind of component that allows me
to
type a MS word document kind of text and if user wants to use the
Font.Bold
in certain text than they have to do it. The rich text doesnot alllow to
use
it in ceartain text to be bold.

So here is my question. How to achive this? Or where I can get good
example
of the
application that does the things that I explained in above.

I can use excel kind of grid or html in Windows Form but why I am not be
able use it the word document in VB.NET 2003.

Does anyone out there to help me, or am I asking too much that is not
possible?

I realy appricate that you spend time to reading my post. And I thank you
for that.

Regs,
Niyazi


Reference Microsoft.Officce.Interop
Install Microsoft Visual Studio 2003 Tools for Officce
 

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

Top