Click to See Complete Forum and Search --> : Linking File
emma rose
July 19th, 1999, 09:47 PM
Hello..
I'm having a problem on how to link a file from another source..
i wrote data in Microsoft word... and that data in a file was keep in a directory C: ..Now i want to retrive that data so that it can come out in the textBox in the VB form.. So that the data can be seen in the textbox on Vb form.. and any changes in the file ... in the vb textbox also change.. i'm having problem of how to do it..please anyone do help me..thank u in advance
Ravi Kiran
July 20th, 1999, 07:50 PM
Hi,
There are a few way to do this.
First of all MS-Word file is not a simple text ( by default. though you can save as simple text. in which case lot of formating info is lost) So give up the idea of showing it in text box. Even RichTextbox will not do, i guess.
You can either use:
1. A Ole control and connect that to your Word document. in which case it will invoke Word application when ever data is edited. This allows both inplace activation (meaning the document can be edited with in the window you have defined for it in your application) or Outofplace activation (in which case a new instance of Word with its own window is opened)
2. Insert a Word-Document control itself. You need to pick it from Project->Controls-> Office objects or something like that.(Just check)
and when you double click it you get the Word (with all its menus & toolbars)
3. Word provides a complete Ole-Automation interface. If you search around you can get a decent num of commands so as to control a seperate instance of Word and make it do as you want. Open up a document, let user edit etc.
Ravi Kiran
emma rose
July 21st, 1999, 08:41 AM
Hi!...
Excuse me... i had problem of locating where is the exactly the word document control in the control list menu... what is the exactly name of the control?
please help me again.. thank u in advance....
Ravi Kiran
July 22nd, 1999, 05:55 AM
Mine is Japanese VB. so i cannot say what that Tab caption in Eng is. It is the 3rd tab on the dialog that props when you select Project->Controls. Caption is something like "Office Objects.."
In that list look for "Microsoft word Document".
This control is slightly sunny in look. It doesn't look all that fine on the form. May be you can go for OLE - control.!!
codeguru.com
Copyright Internet.com Inc., All Rights Reserved.