o
k
q
u
e
s
t
i
o
n
s
.
c
o
m

CreateObject("Word.Application") -

Was a little unsure where to put this but never the less I am sure it will get moved if I am wrong......

anyways - I am running VB6 Professional with Office 2003 installed on the development machine.

I included the reference to "Word 11.0 Object Library" and my CreateObject("Word.Application") Works perfectly..... however if I run my compiles exe on a computer with an older version of Word it crashes. Please does anyone have a method I can use that will work with any version of Word (well 97 onwards)

Many Thanks in advanced

 

CreateObject("Word.Application") -
Was a little unsure where to put this but never the less I am sure it will get moved if I am wrong...... anyways - I am running VB6 Professional with Office 2003 installed on the development machine. I included the reference to "Word 11.0 Object Library" and my CreateOb


Detecting, getting and piloting MS Word from a VB app -
In a VB6 application, I create an MS Word instance and pilot this application directly from the VB application. Using for that the following code : Dim objWord As Object Dim objBasic As Object Set objWord = CreateObject("word.application") Set objBasic = CreateObject


[2005] To create Active X component to Web IIS -
Hi I have developed an application in ASP.NET that opens Word document on any event Here is the code Dim wdDoc, obj As Object obj = CreateObject("Word.application") wdDoc = obj.Documents.Add("C:\MyWordDoc.doc") wdDoc.Application.Visible = True It


CreateObject("Word.Application") generates error "0" -
It saddens me to report another error on which I need your much-appreciated help A user of our app (XP, Word 2007) get's an error with number "0" and no description on CreateObject("Word.Application") in the following bit of code: Code: Private m_Word A


how can i pass data from textbox to word document in vb6 -
if somebody has a different code, it's accepted to see. what if i want to use this code: Private Sub cmdButtom_Click() Dim WordObj As Word.Application Set WordObj = CreateObject("Word.Application") Dim objWord As Word.Document Set objWord = WordObj.Documents.Open(FileName


Microsoft Word Object 8.0 -
I am trying to open word in windows 2000 vb enterprise edition, i added the ref and the lines In Declarations : Option Explicit Dim ObjWord as Word.Application And in Code: Set objWord = New Word.Application 'the error Eve


How to check user has word doc application -
Hi, there, I want to user MS WOrd Application to do spellcheck, Dim x As Object 'create word object variable Set x = CreateObject("Word.Application") How to detect if the user has MS word installed in his local computer? Thanks for any idea and coding! gi


Open Word Document at Run time -
Hello, I want know how to open a word document in VB. I have done it using Createobject but the operations are happining internally (at background) eg. Dim wdapp as word.application Dim wddoc as word.documents Set wordapp = CreateObje


Failed to Create Multiple Word objects VB6 -
Hi Everyone, I'm working on a VB6 program which will process a selected word document. Anyway, I want to allow the users to work on some other MS word documents when the process is running. Because when i run my program, the process will take about 20 mins to finish, it's illogica


Word Templates -
Why can't I create a Word Application object when I execute the following line of code: Set oWordApp = Server.CreateObject("Word.Application.9") It gives the error that I can't create an Out of Process component. I've got Word2000 installed and I got the ProgID above f


Word Application -
Hello everyone! I am Try to use Word Application In My VB Application and i get Run-time Error 5981. Dim X As Object Set X = CreateObject("Word.Application") X.Visible = False X.Documents.Add I am getting this Error in the ADD Command, Any idea?


RESOLVED:Problem opening word template -
Hi I am trying to open a word tempelate from but allways get an error saying that the file is not found. My code is as follows: Dim WordObject As Word.Application Set WordObject = CreateObject("Word.Application") With WordObject .Documents.Open (App.Path


Help with CreateObject -
One of the lines in a program to create an instance of MS Word, is: Set oWord = CreateObject("Word.Application") What must be in the brackets if I wish to create an instance of the word processor of MSWorks?


Word Object exsists -
Hi, If you open a Word Object using say Set Word = CreateObject("word.application") is there a way to set Word = nothing once the user closes that instance of word?


Starting Word... -
I have built an application and tried to launch Word using: _________________________________ Public Sub Send_Word() Dim hWord As Long Dim Appword As Word.Application Dim refstr As String On Error Resume Next 'I have declared previously this function hWord = FindWindow(&q


Word document, change characters -
I have this code to change ALL characters in a WORD Document into character (_). It works but there are also some pictures in the doc and they get lost when I run this. Its also very slow running this. I there someone have suggestions about this ? Code: Private Sub Command1_Cl


Memory problem with Word -
Im using my VB app to get data from a database and fill in Textfields in a Word doc and then print it. Its a rather complex document with lots of textfields and I would like to loop through 5000 records in one run. The problem is, memory used by word rises with each record filled (t


Making the Word window maximum -
Dear VB users, Im my VB application I opened a document in Word with the next code: ############################# Option Explicit Private DocOpen As Word.Application Public Function OpenWord() Set DocOpen = CreateObject("word.application") DocOpen.Visible = Tru


MsgBox does not come to foreground -
There is an application that calls an EXE that I developped in VB.NET This EXE opens a word application: Code: objWordInstance = GetObject(, "Word.Application") If objWordInstance Is Nothing Then objWordInstance = CreateObject("Word.Application")


Error when closing Word application after copy to clipboard -
I'm running the following VBA macro in Excel. The macro creates a Word application which opens an existing document, copies its contents to the clipboard. It then opens a new word application and pastes the clipboard contents into a new document. So far so good. But when I quit the


Detecting if Word2000 is running -
Hi All, I thought that using : Set msword = GetObject(, "Word.Application") Would cause my msword object to latch onto the existing app if it was running otherwise an error 429 would get thrown and I could then use : Set msword = CreateObject("Word.Appli


Vb.Net and Word -
I wrote a program that uses a read only word document to serve as template for creating other documents. After I create and automatically save a new document using the template, I usually like to view it. Sometimes I forget to close word prior to creating another doucment. The resul


Automation Error VB6 -
Hi I am using this code and it was working fine. Now all of a sudden it gives me an error "Runtime error -2147221163 Automation Error Interface not registered Does anyone know how to get rid of this error. This is the code. It is exporting data to MS WORD Dim oWo


Require Fast help -
I'm using VBcode to generate documents in MS word. This process is automated. Everything's working fine but the problem is with WinWord. At the start of code i have instantiated the word object and it looks like this : Dim wdNewWordApplication As Word.Application And then,


Launch external app code problem -
Hi, I'm writing a small menu appn which will give the uses buttons to launch different programs with predefined templates. I have written the following code, which I think should work, but it doesn't, I'm new to VB and can't work it out, any help would be greatly appreciated.


Interface not registered error -
Hi I am using this code and it was working fine. Now all of a sudden it gives me an error "Runtime error -2147221163 Automation Error Interface not registered Does anyone know how to get rid of this error. This is the code. It is exporting data to MS WORD Dim oWord A


Printing multiple copies of a Word document -
Hello, I've researched the forums and have some code that pulls up the print dialog box for Word. However, even if the user enters in the number of copies > 1, only 1 copy is printed. Here is the code I have so far: Option Explicit Private objWord As New Word.Application Pr


OLE Word Objects -
I am just stating with OLE, and I’m weak on objects. First a bit of background, then questions. My first two OLE attempts have had some success. My first attempt was to control MS Word 95 with my VB6 on WMe. It turns out that I can’t use MS Word 95 this way as it does no


Word document problem -
Hi In my app I call a word document that has a letterhead. From the app I populate the document. The problem that I'm having is that the header is being over-written. How can I write to the document without the header beiong over-written? The code is as follows: Dim objWord As Word


Closing Microsoft Word : problem using the Word.Global functions -
Hello there, could (please) anyone help me with this annoying problem? I'm making an application that has to put data on a simple Microsoft Word 2000 document. I use this code for it... --Begin Code-- dim objWrdApp As Word.Application On Error Resume Next Set objWrdApp


Word/ multiuser -
How do I open separate instances of a given word doc for automation. This works for one user: Set app = CreateObject("Word.Application") app.Documents.Open "C:\myMerge.doc" Basically, I want a way to use a template and avoid a document opened/locked conflict


resolved:Curious problem in excel automation... -
I am curious as to what is happening here, I am automating an excel sort command, using this code: main.Range("A1:AM24").Sort Key1:=Range("A2"), Order1:=xlAscending, Header:= _ xlGuess, OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom, _


How to Open Word Doc/ Find/ paste into Excel -
Hi, total newbie at visual basic and I am sorry about this basic question! I have read a few posts and gotten a good start and some results but now I am stuck. I'm writing a VB6 program to open a word doc, find a string, and copy the string into an Excel file. I am able to open


Open Application -
HI, I use the program below for opening microsoft word, If I want to open picture (JPG), what could I do? And how could the program know the microsoft word closed? Code: Dim objWord As Word.Application Dim objDocument As Word.Document obj


open word document with common dialog box -
In a VB program, I am showing the common dialog box to retrieve a word document. Then the user clicks on which word document to open. The document opens but it opens minimized on the task bar. Does anyone know how to have the word document maximized when it opens. My code is: Dim str


To find a word in MS-Word with files having extension .DOC (new try) -
I tried in the following way Dim Appword As Object Dim Wdoc As Document Set Appword = CreateObject("Word.Application") With Application.FileSearch With Appword.FileSearch .NewSearch .LookIn = "C:\My Documents" .SearchSubFolders = True .TextOrProperty =


PLEASE HELP me close Word from VB without messing my print queue -
I AM GOING MAD NOW! Im trying to close a word template and word application after trying to get it to print. The problem is, the print never gets chance to be printed before the code shuts th eapplication. I then get an annoying message telling me that if I close word my jobs in the


word mail merge and asp -
Hi does anyone know how to pass variables from an asp page to a word mail merge query? I am using the following code to open the word document: Dim owd set owd = Server.CreateObject("Word.Application") owd.Documents.Open (server.mapPath("testMailMerge.doc"


Word and VB6 problems -
Hi, I am performing a mail merge in MS Word from VB6. I give the user the option of previewing the print. This works good, except when the user closes the print preview they are left with the word document. I would like it if this was not the case, and when they closed the previe


No toolbar in word -
My app is opening a specific word file with the object "word.application". But , I'm not able to make the word's toolbar visible... here:s my code Code: Set wrdApp = CreateObject("word.application") wrdApp.Documents.Open("FilePath") wrdApp.Appli